unit GL_CCIDS;


interface
uses
  Classes,SysUtils,DB,Uni,UniEngine;

type
  TGLCCIDS=class(TUniEngine)
  private
    FLATESTOPDATE: string;
    FLATESTOPUSER: string;             
    FCOAID    : string;
    FASID     : string;
    FENID     : string;
    FMKID     : string;
    FBSID     : string;
    FBIID     : string;
    FBSIID    : string;
    FPKID     : string;
    FBOID     : string;
    FBKID     : string;
    FMBID     : string;
    FFILEID   : string;
    FPMID     : string;
    FINBSID   : string;
    FINBISID  : string;
    FCBID     : string;
    FPBID     : string;
    FIBID     : string;
    FBACID    : string;
    FBAPID    : string;
    FBAIID    : string;
    FBTID     : string;
    FBPID     : string;
    FBLID     : string;
    FHOLD1ID  : string;
    FHOLD2ID  : string;
    FHOLD3ID  : string;
    FHOLD4ID  : string;
    FHOLD5ID  : string;
    FHOLD6ID  : string;
    FHOLD7ID  : string;
    FHOLD8ID  : string;
    FHOLD9ID  : string;
    FHOLD10ID : string;
    FHOLD11ID : string;
    FHOLD12ID : string;
    FHOLD13ID : string;
    FHOLD14ID : string;
    FHOLD15ID : string;
    FHOLD16ID : string;
    FHOLD17ID : string;
    FHOLD18ID : string;
    FHOLD19ID : string;
    FHOLD20ID : string;
    FHOLD21ID : string;
    FHOLD22ID : string;
    FHOLD23ID : string;
    FHOLD24ID : string;
    FHOLD25ID : string;
    FHOLD26ID : string;
    FHOLD27ID : string;
    FHOLD28ID : string;
    FHOLD29ID : string;
    FHOLD30ID : string;
    FSETYEAR  : Extended;
    FBISID    : string;
    FINPMID   : string;
    FSTID     : string;
    FCTID     : string;
    FSMID     : string;
    FOPUSERID : string;
    FEDITORID : string;
    FGBID     : string;
    FFMID     : string;
    FASCODE   : string;
    FASNAME   : string;
    FENCODE   : string;
    FENNAME   : string;
    FMKCODE   : string;
    FMKNAME   : string;
    FBSCODE   : string;
    FBSNAME   : string;
    FBICODE   : string;
    FBINAME   : string;
    FBSICODE  : string;
    FBSINAME  : string;
    FPKCODE   : string;
    FPKNAME   : string;
    FBOCODE   : string;
    FBONAME   : string;
    FBKCODE   : string;
    FBKNAME   : string;
    FMBCODE   : string;
    FMBNAME   : string;
    FFILECODE : string;
    FFILENAME : string;
    FPMCODE   : string;
    FPMNAME   : string;
    FINBSCODE : string;
    FINBSNAME : string;
    FINBISCODE: string;
    FINBISNAME: string;
    FCBCODE   : string;
    FCBNAME   : string;
    FPBCODE   : string;
    FPBNAME   : string;
    FIBCODE   : string;
    FIBNAME   : string;
    FBACCODE  : string;
    FBACNAME  : string;
    FBAPCODE  : string;
    FBAPNAME  : string;
    FBAICODE  : string;
    FBAINAME  : string;
    FBTCODE   : string;
    FBTNAME   : string;
    FBPCODE   : string;
    FBPNAME   : string;
    FBLCODE   : string;
    FBLNAME   : string;
    FHOLD1CODE: string;
    FHOLD1NAME: string;
    FHOLD2CODE: string;
    FHOLD2NAME: string;
    FHOLD3CODE: string;
    FHOLD3NAME: string;
    FHOLD4CODE: string;
    FHOLD4NAME: string;
    FHOLD5CODE: string;
    FHOLD5NAME: string;
    FHOLD6CODE: string;
    FHOLD6NAME: string;
    FHOLD7CODE: string;
    FHOLD7NAME: string;
    FHOLD8CODE: string;
    FHOLD8NAME: string;
    FHOLD9CODE: string;
    FHOLD9NAME: string;
    FHOLD10CODE: string;
    FHOLD10NAME: string;
    FHOLD11CODE: string;
    FHOLD11NAME: string;
    FHOLD12CODE: string;
    FHOLD12NAME: string;
    FHOLD13CODE: string;
    FHOLD13NAME: string;
    FHOLD14CODE: string;
    FHOLD14NAME: string;
    FHOLD15CODE: string;
    FHOLD15NAME: string;
    FHOLD16CODE: string;
    FHOLD16NAME: string;
    FHOLD17CODE: string;
    FHOLD17NAME: string;
    FHOLD18CODE: string;
    FHOLD18NAME: string;
    FHOLD19CODE: string;
    FHOLD19NAME: string;
    FHOLD20CODE: string;
    FHOLD20NAME: string;
    FHOLD21CODE: string;
    FHOLD21NAME: string;
    FHOLD22CODE: string;
    FHOLD22NAME: string;
    FHOLD23CODE: string;
    FHOLD23NAME: string;
    FHOLD24CODE: string;
    FHOLD24NAME: string;
    FHOLD25CODE: string;
    FHOLD25NAME: string;
    FHOLD26CODE: string;
    FHOLD26NAME: string;
    FHOLD27CODE: string;
    FHOLD27NAME: string;
    FHOLD28CODE: string;
    FHOLD28NAME: string;
    FHOLD29CODE: string;
    FHOLD29NAME: string;
    FHOLD30CODE: string;
    FHOLD30NAME: string;
    FBISCODE  : string;
    FBISNAME  : string;
    FINPMCODE : string;
    FINPMNAME : string;
    FSTCODE   : string;
    FSTNAME   : string;
    FCTCODE   : string;
    FCTNAME   : string;
    FSMCODE   : string;
    FSMNAME   : string;
    FOPUSERCODE: string;
    FOPUSERNAME: string;
    FEDITORCODE: string;
    FEDITORNAME: string;
    FGBCODE   : string;
    FGBNAME   : string;
    FFMCODE   : string;
    FFMNAME   : string;
    FPAYACCOUNTNO: string;
    FPAYACCOUNTNAME: string;
    FPAYACCOUNTBANK: string;
    FCLEARACCOUNTNO: string;
    FCLEARACCOUNTNAME: string;
    FCLEARACCOUNTBANK: string;
    FINCOMEACCOUNTNO: string;
    FINCOMEACCOUNTNAME: string;
    FINCOMEACCOUNTBANK: string;
    FPFID     : string;
    FPFCODE   : string;
    FPFNAME   : string;
    FGROUPIDID: string;
    FGROUPIDCODE: string;
    FGROUPIDNAME: string;
    FUSEENID  : string;
    FUSEENCODE: string;
    FUSEENNAME: string;
    FPROVID   : string;
    FPROVCODE : string;
    FPROVNAME : string;
    FAGENCYID : string;
    FAGENCYCODE: string;
    FAGENCYNAME: string;
    FMODEID   : string;
    FMODECODE : string;
    FMODENAME : string;
    FFASNID   : string;
    FFASNCODE : string;
    FFASNNAME : string;
    FDIRID    : string;
    FDIRCODE  : string;
    FDIRNAME  : string;
    FGPPLANID : string;
    FGPPLANCODE: string;
    FGPPLANNAME: string;
    FGPBARNID : string;
    FGPBARNCODE: string;
    FGPBARNNAME: string;
    FWAID     : string;
    FWACODE   : string;
    FWANAME   : string;
    FFFID     : string;
    FFFNAME   : string;
    FFFCODE   : string;
    FIENID    : string;
    FIENNAME  : string;
    FIENCODE  : string;
    FSALTAGID : string;
    FSALTAGNAME: string;
    FSALTAGCODE: string;
    FBCID     : string;
    FBCCODE   : string;
    FBCNAME   : string;
    FBSOID    : string;
    FBSOCODE  : string;
    FBSONAME  : string;
    FAEID     : string;
    FAECODE   : string;
    FAENAME   : string;
    FCCID     : Extended;
    FBUDGETVOUID: string;
    FBUDGETVOUCODE: string;
    FBUDGETVOUNAME: string;
    FMD5      : string;
    FGPVOUID  : string;
    FGPVOUCODE: string;
    FGPVOUNAME: string;
  protected
    procedure SetParameters;override;
    function  GetStrInsert:string;override;
    function  GetStrUpdate:string;override;
    function  GetStrDelete:string;override;
  public
    function  GetStrsIndex:string;override;
  public
    function  GetNextIdex:Integer;overload;
    function  GetNextIdex(AUniConnection:TUniConnection):Integer;overload;
    function  GetNextMAXX(AUniConnection:TUniConnection):Extended;
  public
    function  CheckExist(AUniConnection:TUniConnection):Boolean;override;
    function  ExpSQL:string;
  public
    destructor  Destroy; override;
    constructor Create;  
  published
    property LATESTOPDATE: string read FLATESTOPDATE write FLATESTOPDATE;
    property LATESTOPUSER: string read FLATESTOPUSER write FLATESTOPUSER;
    property COAID    : string read FCOAID     write FCOAID;
    property ASID     : string read FASID      write FASID;
    property ENID     : string read FENID      write FENID;
    property MKID     : string read FMKID      write FMKID;
    property BSID     : string read FBSID      write FBSID;
    property BIID     : string read FBIID      write FBIID;
    property BSIID    : string read FBSIID     write FBSIID;
    property PKID     : string read FPKID      write FPKID;
    property BOID     : string read FBOID      write FBOID;
    property BKID     : string read FBKID      write FBKID;
    property MBID     : string read FMBID      write FMBID;
    property FILEID   : string read FFILEID    write FFILEID;
    property PMID     : string read FPMID      write FPMID;
    property INBSID   : string read FINBSID    write FINBSID;
    property INBISID  : string read FINBISID   write FINBISID;
    property CBID     : string read FCBID      write FCBID;
    property PBID     : string read FPBID      write FPBID;
    property IBID     : string read FIBID      write FIBID;
    property BACID    : string read FBACID     write FBACID;
    property BAPID    : string read FBAPID     write FBAPID;
    property BAIID    : string read FBAIID     write FBAIID;
    property BTID     : string read FBTID      write FBTID;
    property BPID     : string read FBPID      write FBPID;
    property BLID     : string read FBLID      write FBLID;
    property HOLD1ID  : string read FHOLD1ID   write FHOLD1ID;
    property HOLD2ID  : string read FHOLD2ID   write FHOLD2ID;
    property HOLD3ID  : string read FHOLD3ID   write FHOLD3ID;
    property HOLD4ID  : string read FHOLD4ID   write FHOLD4ID;
    property HOLD5ID  : string read FHOLD5ID   write FHOLD5ID;
    property HOLD6ID  : string read FHOLD6ID   write FHOLD6ID;
    property HOLD7ID  : string read FHOLD7ID   write FHOLD7ID;
    property HOLD8ID  : string read FHOLD8ID   write FHOLD8ID;
    property HOLD9ID  : string read FHOLD9ID   write FHOLD9ID;
    property HOLD10ID : string read FHOLD10ID  write FHOLD10ID;
    property HOLD11ID : string read FHOLD11ID  write FHOLD11ID;
    property HOLD12ID : string read FHOLD12ID  write FHOLD12ID;
    property HOLD13ID : string read FHOLD13ID  write FHOLD13ID;
    property HOLD14ID : string read FHOLD14ID  write FHOLD14ID;
    property HOLD15ID : string read FHOLD15ID  write FHOLD15ID;
    property HOLD16ID : string read FHOLD16ID  write FHOLD16ID;
    property HOLD17ID : string read FHOLD17ID  write FHOLD17ID;
    property HOLD18ID : string read FHOLD18ID  write FHOLD18ID;
    property HOLD19ID : string read FHOLD19ID  write FHOLD19ID;
    property HOLD20ID : string read FHOLD20ID  write FHOLD20ID;
    property HOLD21ID : string read FHOLD21ID  write FHOLD21ID;
    property HOLD22ID : string read FHOLD22ID  write FHOLD22ID;
    property HOLD23ID : string read FHOLD23ID  write FHOLD23ID;
    property HOLD24ID : string read FHOLD24ID  write FHOLD24ID;
    property HOLD25ID : string read FHOLD25ID  write FHOLD25ID;
    property HOLD26ID : string read FHOLD26ID  write FHOLD26ID;
    property HOLD27ID : string read FHOLD27ID  write FHOLD27ID;
    property HOLD28ID : string read FHOLD28ID  write FHOLD28ID;
    property HOLD29ID : string read FHOLD29ID  write FHOLD29ID;
    property HOLD30ID : string read FHOLD30ID  write FHOLD30ID;
    property SETYEAR  : Extended read FSETYEAR   write FSETYEAR;
    property BISID    : string read FBISID     write FBISID;
    property INPMID   : string read FINPMID    write FINPMID;
    property STID     : string read FSTID      write FSTID;
    property CTID     : string read FCTID      write FCTID;
    property SMID     : string read FSMID      write FSMID;
    property OPUSERID : string read FOPUSERID  write FOPUSERID;
    property EDITORID : string read FEDITORID  write FEDITORID;
    property GBID     : string read FGBID      write FGBID;
    property FMID     : string read FFMID      write FFMID;
    property ASCODE   : string read FASCODE    write FASCODE;
    property ASNAME   : string read FASNAME    write FASNAME;
    property ENCODE   : string read FENCODE    write FENCODE;
    property ENNAME   : string read FENNAME    write FENNAME;
    property MKCODE   : string read FMKCODE    write FMKCODE;
    property MKNAME   : string read FMKNAME    write FMKNAME;
    property BSCODE   : string read FBSCODE    write FBSCODE;
    property BSNAME   : string read FBSNAME    write FBSNAME;
    property BICODE   : string read FBICODE    write FBICODE;
    property BINAME   : string read FBINAME    write FBINAME;
    property BSICODE  : string read FBSICODE   write FBSICODE;
    property BSINAME  : string read FBSINAME   write FBSINAME;
    property PKCODE   : string read FPKCODE    write FPKCODE;
    property PKNAME   : string read FPKNAME    write FPKNAME;
    property BOCODE   : string read FBOCODE    write FBOCODE;
    property BONAME   : string read FBONAME    write FBONAME;
    property BKCODE   : string read FBKCODE    write FBKCODE;
    property BKNAME   : string read FBKNAME    write FBKNAME;
    property MBCODE   : string read FMBCODE    write FMBCODE;
    property MBNAME   : string read FMBNAME    write FMBNAME;
    property FILECODE : string read FFILECODE  write FFILECODE;
    property FILENAME : string read FFILENAME  write FFILENAME;
    property PMCODE   : string read FPMCODE    write FPMCODE;
    property PMNAME   : string read FPMNAME    write FPMNAME;
    property INBSCODE : string read FINBSCODE  write FINBSCODE;
    property INBSNAME : string read FINBSNAME  write FINBSNAME;
    property INBISCODE: string read FINBISCODE write FINBISCODE;
    property INBISNAME: string read FINBISNAME write FINBISNAME;
    property CBCODE   : string read FCBCODE    write FCBCODE;
    property CBNAME   : string read FCBNAME    write FCBNAME;
    property PBCODE   : string read FPBCODE    write FPBCODE;
    property PBNAME   : string read FPBNAME    write FPBNAME;
    property IBCODE   : string read FIBCODE    write FIBCODE;
    property IBNAME   : string read FIBNAME    write FIBNAME;
    property BACCODE  : string read FBACCODE   write FBACCODE;
    property BACNAME  : string read FBACNAME   write FBACNAME;
    property BAPCODE  : string read FBAPCODE   write FBAPCODE;
    property BAPNAME  : string read FBAPNAME   write FBAPNAME;
    property BAICODE  : string read FBAICODE   write FBAICODE;
    property BAINAME  : string read FBAINAME   write FBAINAME;
    property BTCODE   : string read FBTCODE    write FBTCODE;
    property BTNAME   : string read FBTNAME    write FBTNAME;
    property BPCODE   : string read FBPCODE    write FBPCODE;
    property BPNAME   : string read FBPNAME    write FBPNAME;
    property BLCODE   : string read FBLCODE    write FBLCODE;
    property BLNAME   : string read FBLNAME    write FBLNAME;
    property HOLD1CODE: string read FHOLD1CODE write FHOLD1CODE;
    property HOLD1NAME: string read FHOLD1NAME write FHOLD1NAME;
    property HOLD2CODE: string read FHOLD2CODE write FHOLD2CODE;
    property HOLD2NAME: string read FHOLD2NAME write FHOLD2NAME;
    property HOLD3CODE: string read FHOLD3CODE write FHOLD3CODE;
    property HOLD3NAME: string read FHOLD3NAME write FHOLD3NAME;
    property HOLD4CODE: string read FHOLD4CODE write FHOLD4CODE;
    property HOLD4NAME: string read FHOLD4NAME write FHOLD4NAME;
    property HOLD5CODE: string read FHOLD5CODE write FHOLD5CODE;
    property HOLD5NAME: string read FHOLD5NAME write FHOLD5NAME;
    property HOLD6CODE: string read FHOLD6CODE write FHOLD6CODE;
    property HOLD6NAME: string read FHOLD6NAME write FHOLD6NAME;
    property HOLD7CODE: string read FHOLD7CODE write FHOLD7CODE;
    property HOLD7NAME: string read FHOLD7NAME write FHOLD7NAME;
    property HOLD8CODE: string read FHOLD8CODE write FHOLD8CODE;
    property HOLD8NAME: string read FHOLD8NAME write FHOLD8NAME;
    property HOLD9CODE: string read FHOLD9CODE write FHOLD9CODE;
    property HOLD9NAME: string read FHOLD9NAME write FHOLD9NAME;
    property HOLD10CODE: string read FHOLD10CODE write FHOLD10CODE;
    property HOLD10NAME: string read FHOLD10NAME write FHOLD10NAME;
    property HOLD11CODE: string read FHOLD11CODE write FHOLD11CODE;
    property HOLD11NAME: string read FHOLD11NAME write FHOLD11NAME;
    property HOLD12CODE: string read FHOLD12CODE write FHOLD12CODE;
    property HOLD12NAME: string read FHOLD12NAME write FHOLD12NAME;
    property HOLD13CODE: string read FHOLD13CODE write FHOLD13CODE;
    property HOLD13NAME: string read FHOLD13NAME write FHOLD13NAME;
    property HOLD14CODE: string read FHOLD14CODE write FHOLD14CODE;
    property HOLD14NAME: string read FHOLD14NAME write FHOLD14NAME;
    property HOLD15CODE: string read FHOLD15CODE write FHOLD15CODE;
    property HOLD15NAME: string read FHOLD15NAME write FHOLD15NAME;
    property HOLD16CODE: string read FHOLD16CODE write FHOLD16CODE;
    property HOLD16NAME: string read FHOLD16NAME write FHOLD16NAME;
    property HOLD17CODE: string read FHOLD17CODE write FHOLD17CODE;
    property HOLD17NAME: string read FHOLD17NAME write FHOLD17NAME;
    property HOLD18CODE: string read FHOLD18CODE write FHOLD18CODE;
    property HOLD18NAME: string read FHOLD18NAME write FHOLD18NAME;
    property HOLD19CODE: string read FHOLD19CODE write FHOLD19CODE;
    property HOLD19NAME: string read FHOLD19NAME write FHOLD19NAME;
    property HOLD20CODE: string read FHOLD20CODE write FHOLD20CODE;
    property HOLD20NAME: string read FHOLD20NAME write FHOLD20NAME;
    property HOLD21CODE: string read FHOLD21CODE write FHOLD21CODE;
    property HOLD21NAME: string read FHOLD21NAME write FHOLD21NAME;
    property HOLD22CODE: string read FHOLD22CODE write FHOLD22CODE;
    property HOLD22NAME: string read FHOLD22NAME write FHOLD22NAME;
    property HOLD23CODE: string read FHOLD23CODE write FHOLD23CODE;
    property HOLD23NAME: string read FHOLD23NAME write FHOLD23NAME;
    property HOLD24CODE: string read FHOLD24CODE write FHOLD24CODE;
    property HOLD24NAME: string read FHOLD24NAME write FHOLD24NAME;
    property HOLD25CODE: string read FHOLD25CODE write FHOLD25CODE;
    property HOLD25NAME: string read FHOLD25NAME write FHOLD25NAME;
    property HOLD26CODE: string read FHOLD26CODE write FHOLD26CODE;
    property HOLD26NAME: string read FHOLD26NAME write FHOLD26NAME;
    property HOLD27CODE: string read FHOLD27CODE write FHOLD27CODE;
    property HOLD27NAME: string read FHOLD27NAME write FHOLD27NAME;
    property HOLD28CODE: string read FHOLD28CODE write FHOLD28CODE;
    property HOLD28NAME: string read FHOLD28NAME write FHOLD28NAME;
    property HOLD29CODE: string read FHOLD29CODE write FHOLD29CODE;
    property HOLD29NAME: string read FHOLD29NAME write FHOLD29NAME;
    property HOLD30CODE: string read FHOLD30CODE write FHOLD30CODE;
    property HOLD30NAME: string read FHOLD30NAME write FHOLD30NAME;
    property BISCODE  : string read FBISCODE   write FBISCODE;
    property BISNAME  : string read FBISNAME   write FBISNAME;
    property INPMCODE : string read FINPMCODE  write FINPMCODE;
    property INPMNAME : string read FINPMNAME  write FINPMNAME;
    property STCODE   : string read FSTCODE    write FSTCODE;
    property STNAME   : string read FSTNAME    write FSTNAME;
    property CTCODE   : string read FCTCODE    write FCTCODE;
    property CTNAME   : string read FCTNAME    write FCTNAME;
    property SMCODE   : string read FSMCODE    write FSMCODE;
    property SMNAME   : string read FSMNAME    write FSMNAME;
    property OPUSERCODE: string read FOPUSERCODE write FOPUSERCODE;
    property OPUSERNAME: string read FOPUSERNAME write FOPUSERNAME;
    property EDITORCODE: string read FEDITORCODE write FEDITORCODE;
    property EDITORNAME: string read FEDITORNAME write FEDITORNAME;
    property GBCODE   : string read FGBCODE    write FGBCODE;
    property GBNAME   : string read FGBNAME    write FGBNAME;
    property FMCODE   : string read FFMCODE    write FFMCODE;
    property FMNAME   : string read FFMNAME    write FFMNAME;
    property PAYACCOUNTNO: string read FPAYACCOUNTNO write FPAYACCOUNTNO;
    property PAYACCOUNTNAME: string read FPAYACCOUNTNAME write FPAYACCOUNTNAME;
    property PAYACCOUNTBANK: string read FPAYACCOUNTBANK write FPAYACCOUNTBANK;
    property CLEARACCOUNTNO: string read FCLEARACCOUNTNO write FCLEARACCOUNTNO;
    property CLEARACCOUNTNAME: string read FCLEARACCOUNTNAME write FCLEARACCOUNTNAME;
    property CLEARACCOUNTBANK: string read FCLEARACCOUNTBANK write FCLEARACCOUNTBANK;
    property INCOMEACCOUNTNO: string read FINCOMEACCOUNTNO write FINCOMEACCOUNTNO;
    property INCOMEACCOUNTNAME: string read FINCOMEACCOUNTNAME write FINCOMEACCOUNTNAME;
    property INCOMEACCOUNTBANK: string read FINCOMEACCOUNTBANK write FINCOMEACCOUNTBANK;
    property PFID     : string read FPFID      write FPFID;
    property PFCODE   : string read FPFCODE    write FPFCODE;
    property PFNAME   : string read FPFNAME    write FPFNAME;
    property GROUPIDID: string read FGROUPIDID write FGROUPIDID;
    property GROUPIDCODE: string read FGROUPIDCODE write FGROUPIDCODE;
    property GROUPIDNAME: string read FGROUPIDNAME write FGROUPIDNAME;
    property USEENID  : string read FUSEENID   write FUSEENID;
    property USEENCODE: string read FUSEENCODE write FUSEENCODE;
    property USEENNAME: string read FUSEENNAME write FUSEENNAME;
    property PROVID   : string read FPROVID    write FPROVID;
    property PROVCODE : string read FPROVCODE  write FPROVCODE;
    property PROVNAME : string read FPROVNAME  write FPROVNAME;
    property AGENCYID : string read FAGENCYID  write FAGENCYID;
    property AGENCYCODE: string read FAGENCYCODE write FAGENCYCODE;
    property AGENCYNAME: string read FAGENCYNAME write FAGENCYNAME;
    property MODEID   : string read FMODEID    write FMODEID;
    property MODECODE : string read FMODECODE  write FMODECODE;
    property MODENAME : string read FMODENAME  write FMODENAME;
    property FASNID   : string read FFASNID    write FFASNID;
    property FASNCODE : string read FFASNCODE  write FFASNCODE;
    property FASNNAME : string read FFASNNAME  write FFASNNAME;
    property DIRID    : string read FDIRID     write FDIRID;
    property DIRCODE  : string read FDIRCODE   write FDIRCODE;
    property DIRNAME  : string read FDIRNAME   write FDIRNAME;
    property GPPLANID : string read FGPPLANID  write FGPPLANID;
    property GPPLANCODE: string read FGPPLANCODE write FGPPLANCODE;
    property GPPLANNAME: string read FGPPLANNAME write FGPPLANNAME;
    property GPBARNID : string read FGPBARNID  write FGPBARNID;
    property GPBARNCODE: string read FGPBARNCODE write FGPBARNCODE;
    property GPBARNNAME: string read FGPBARNNAME write FGPBARNNAME;
    property WAID     : string read FWAID      write FWAID;
    property WACODE   : string read FWACODE    write FWACODE;
    property WANAME   : string read FWANAME    write FWANAME;
    property FFID     : string read FFFID      write FFFID;
    property FFNAME   : string read FFFNAME    write FFFNAME;
    property FFCODE   : string read FFFCODE    write FFFCODE;
    property IENID    : string read FIENID     write FIENID;
    property IENNAME  : string read FIENNAME   write FIENNAME;
    property IENCODE  : string read FIENCODE   write FIENCODE;
    property SALTAGID : string read FSALTAGID  write FSALTAGID;
    property SALTAGNAME: string read FSALTAGNAME write FSALTAGNAME;
    property SALTAGCODE: string read FSALTAGCODE write FSALTAGCODE;
    property BCID     : string read FBCID      write FBCID;
    property BCCODE   : string read FBCCODE    write FBCCODE;
    property BCNAME   : string read FBCNAME    write FBCNAME;
    property BSOID    : string read FBSOID     write FBSOID;
    property BSOCODE  : string read FBSOCODE   write FBSOCODE;
    property BSONAME  : string read FBSONAME   write FBSONAME;
    property AEID     : string read FAEID      write FAEID;
    property AECODE   : string read FAECODE    write FAECODE;
    property AENAME   : string read FAENAME    write FAENAME;
    property CCID     : Extended read FCCID      write FCCID;
    property BUDGETVOUID: string read FBUDGETVOUID write FBUDGETVOUID;
    property BUDGETVOUCODE: string read FBUDGETVOUCODE write FBUDGETVOUCODE;
    property BUDGETVOUNAME: string read FBUDGETVOUNAME write FBUDGETVOUNAME;
    property MD5      : string read FMD5       write FMD5;
    property GPVOUID  : string read FGPVOUID   write FGPVOUID;
    property GPVOUCODE: string read FGPVOUCODE write FGPVOUCODE;
    property GPVOUNAME: string read FGPVOUNAME write FGPVOUNAME;    
  public
    class function  ReadDS(AUniQuery:TUniQuery):TUniEngine;override;
    class procedure ReadDS(AUniQuery:TUniQuery;var Result:TUniEngine);override;
    class function  CopyIt(AGLCCIDS:TGLCCIDS):TGLCCIDS;overload;        
    class procedure CopyIt(AGLCCIDS:TGLCCIDS;var Result:TGLCCIDS);overload;       
  end;

implementation

{ TGLCCIDS }
procedure TGLCCIDS.SetParameters;
begin
  inherited;
  with FUniSQL.Params do
  begin
    case FOptTyp of
      otAddx:
      begin
        ParamByName('LATEST_OP_DATE').Value := LATESTOPDATE;
        ParamByName('LATEST_OP_USER').Value := LATESTOPUSER;
        ParamByName('COA_ID').Value := COAID;
        ParamByName('AS_ID').Value := ASID;
        ParamByName('EN_ID').Value := ENID;
        ParamByName('MK_ID').Value := MKID;
        ParamByName('BS_ID').Value := BSID;
        ParamByName('BI_ID').Value := BIID;
        ParamByName('BSI_ID').Value := BSIID;
        ParamByName('PK_ID').Value := PKID;
        ParamByName('BO_ID').Value := BOID;
        ParamByName('BK_ID').Value := BKID;
        ParamByName('MB_ID').Value := MBID;
        ParamByName('FILE_ID').Value := FILEID;
        ParamByName('PM_ID').Value := PMID;
        ParamByName('IN_BS_ID').Value := INBSID;
        ParamByName('IN_BIS_ID').Value := INBISID;
        ParamByName('CB_ID').Value := CBID;
        ParamByName('PB_ID').Value := PBID;
        ParamByName('IB_ID').Value := IBID;
        ParamByName('BAC_ID').Value := BACID;
        ParamByName('BAP_ID').Value := BAPID;
        ParamByName('BAI_ID').Value := BAIID;
        ParamByName('BT_ID').Value := BTID;
        ParamByName('BP_ID').Value := BPID;
        ParamByName('BL_ID').Value := BLID;
        ParamByName('HOLD1_ID').Value := HOLD1ID;
        ParamByName('HOLD2_ID').Value := HOLD2ID;
        ParamByName('HOLD3_ID').Value := HOLD3ID;
        ParamByName('HOLD4_ID').Value := HOLD4ID;
        ParamByName('HOLD5_ID').Value := HOLD5ID;
        ParamByName('HOLD6_ID').Value := HOLD6ID;
        ParamByName('HOLD7_ID').Value := HOLD7ID;
        ParamByName('HOLD8_ID').Value := HOLD8ID;
        ParamByName('HOLD9_ID').Value := HOLD9ID;
        ParamByName('HOLD10_ID').Value := HOLD10ID;
        ParamByName('HOLD11_ID').Value := HOLD11ID;
        ParamByName('HOLD12_ID').Value := HOLD12ID;
        ParamByName('HOLD13_ID').Value := HOLD13ID;
        ParamByName('HOLD14_ID').Value := HOLD14ID;
        ParamByName('HOLD15_ID').Value := HOLD15ID;
        ParamByName('HOLD16_ID').Value := HOLD16ID;
        ParamByName('HOLD17_ID').Value := HOLD17ID;
        ParamByName('HOLD18_ID').Value := HOLD18ID;
        ParamByName('HOLD19_ID').Value := HOLD19ID;
        ParamByName('HOLD20_ID').Value := HOLD20ID;
        ParamByName('HOLD21_ID').Value := HOLD21ID;
        ParamByName('HOLD22_ID').Value := HOLD22ID;
        ParamByName('HOLD23_ID').Value := HOLD23ID;
        ParamByName('HOLD24_ID').Value := HOLD24ID;
        ParamByName('HOLD25_ID').Value := HOLD25ID;
        ParamByName('HOLD26_ID').Value := HOLD26ID;
        ParamByName('HOLD27_ID').Value := HOLD27ID;
        ParamByName('HOLD28_ID').Value := HOLD28ID;
        ParamByName('HOLD29_ID').Value := HOLD29ID;
        ParamByName('HOLD30_ID').Value := HOLD30ID;
        ParamByName('SET_YEAR').Value := SETYEAR;
        ParamByName('BIS_ID').Value := BISID;
        ParamByName('INPM_ID').Value := INPMID;
        ParamByName('ST_ID').Value := STID;
        ParamByName('CT_ID').Value := CTID;
        ParamByName('SM_ID').Value := SMID;
        ParamByName('OPUSER_ID').Value := OPUSERID;
        ParamByName('EDITOR_ID').Value := EDITORID;
        ParamByName('GB_ID').Value := GBID;
        ParamByName('FM_ID').Value := FMID;
        ParamByName('AS_CODE').Value := ASCODE;
        ParamByName('AS_NAME').Value := ASNAME;
        ParamByName('EN_CODE').Value := ENCODE;
        ParamByName('EN_NAME').Value := ENNAME;
        ParamByName('MK_CODE').Value := MKCODE;
        ParamByName('MK_NAME').Value := MKNAME;
        ParamByName('BS_CODE').Value := BSCODE;
        ParamByName('BS_NAME').Value := BSNAME;
        ParamByName('BI_CODE').Value := BICODE;
        ParamByName('BI_NAME').Value := BINAME;
        ParamByName('BSI_CODE').Value := BSICODE;
        ParamByName('BSI_NAME').Value := BSINAME;
        ParamByName('PK_CODE').Value := PKCODE;
        ParamByName('PK_NAME').Value := PKNAME;
        ParamByName('BO_CODE').Value := BOCODE;
        ParamByName('BO_NAME').Value := BONAME;
        ParamByName('BK_CODE').Value := BKCODE;
        ParamByName('BK_NAME').Value := BKNAME;
        ParamByName('MB_CODE').Value := MBCODE;
        ParamByName('MB_NAME').Value := MBNAME;
        ParamByName('FILE_CODE').Value := FILECODE;
        ParamByName('FILE_NAME').Value := FILENAME;
        ParamByName('PM_CODE').Value := PMCODE;
        ParamByName('PM_NAME').Value := PMNAME;
        ParamByName('IN_BS_CODE').Value := INBSCODE;
        ParamByName('IN_BS_NAME').Value := INBSNAME;
        ParamByName('IN_BIS_CODE').Value := INBISCODE;
        ParamByName('IN_BIS_NAME').Value := INBISNAME;
        ParamByName('CB_CODE').Value := CBCODE;
        ParamByName('CB_NAME').Value := CBNAME;
        ParamByName('PB_CODE').Value := PBCODE;
        ParamByName('PB_NAME').Value := PBNAME;
        ParamByName('IB_CODE').Value := IBCODE;
        ParamByName('IB_NAME').Value := IBNAME;
        ParamByName('BAC_CODE').Value := BACCODE;
        ParamByName('BAC_NAME').Value := BACNAME;
        ParamByName('BAP_CODE').Value := BAPCODE;
        ParamByName('BAP_NAME').Value := BAPNAME;
        ParamByName('BAI_CODE').Value := BAICODE;
        ParamByName('BAI_NAME').Value := BAINAME;
        ParamByName('BT_CODE').Value := BTCODE;
        ParamByName('BT_NAME').Value := BTNAME;
        ParamByName('BP_CODE').Value := BPCODE;
        ParamByName('BP_NAME').Value := BPNAME;
        ParamByName('BL_CODE').Value := BLCODE;
        ParamByName('BL_NAME').Value := BLNAME;
        ParamByName('HOLD1_CODE').Value := HOLD1CODE;
        ParamByName('HOLD1_NAME').Value := HOLD1NAME;
        ParamByName('HOLD2_CODE').Value := HOLD2CODE;
        ParamByName('HOLD2_NAME').Value := HOLD2NAME;
        ParamByName('HOLD3_CODE').Value := HOLD3CODE;
        ParamByName('HOLD3_NAME').Value := HOLD3NAME;
        ParamByName('HOLD4_CODE').Value := HOLD4CODE;
        ParamByName('HOLD4_NAME').Value := HOLD4NAME;
        ParamByName('HOLD5_CODE').Value := HOLD5CODE;
        ParamByName('HOLD5_NAME').Value := HOLD5NAME;
        ParamByName('HOLD6_CODE').Value := HOLD6CODE;
        ParamByName('HOLD6_NAME').Value := HOLD6NAME;
        ParamByName('HOLD7_CODE').Value := HOLD7CODE;
        ParamByName('HOLD7_NAME').Value := HOLD7NAME;
        ParamByName('HOLD8_CODE').Value := HOLD8CODE;
        ParamByName('HOLD8_NAME').Value := HOLD8NAME;
        ParamByName('HOLD9_CODE').Value := HOLD9CODE;
        ParamByName('HOLD9_NAME').Value := HOLD9NAME;
        ParamByName('HOLD10_CODE').Value := HOLD10CODE;
        ParamByName('HOLD10_NAME').Value := HOLD10NAME;
        ParamByName('HOLD11_CODE').Value := HOLD11CODE;
        ParamByName('HOLD11_NAME').Value := HOLD11NAME;
        ParamByName('HOLD12_CODE').Value := HOLD12CODE;
        ParamByName('HOLD12_NAME').Value := HOLD12NAME;
        ParamByName('HOLD13_CODE').Value := HOLD13CODE;
        ParamByName('HOLD13_NAME').Value := HOLD13NAME;
        ParamByName('HOLD14_CODE').Value := HOLD14CODE;
        ParamByName('HOLD14_NAME').Value := HOLD14NAME;
        ParamByName('HOLD15_CODE').Value := HOLD15CODE;
        ParamByName('HOLD15_NAME').Value := HOLD15NAME;
        ParamByName('HOLD16_CODE').Value := HOLD16CODE;
        ParamByName('HOLD16_NAME').Value := HOLD16NAME;
        ParamByName('HOLD17_CODE').Value := HOLD17CODE;
        ParamByName('HOLD17_NAME').Value := HOLD17NAME;
        ParamByName('HOLD18_CODE').Value := HOLD18CODE;
        ParamByName('HOLD18_NAME').Value := HOLD18NAME;
        ParamByName('HOLD19_CODE').Value := HOLD19CODE;
        ParamByName('HOLD19_NAME').Value := HOLD19NAME;
        ParamByName('HOLD20_CODE').Value := HOLD20CODE;
        ParamByName('HOLD20_NAME').Value := HOLD20NAME;
        ParamByName('HOLD21_CODE').Value := HOLD21CODE;
        ParamByName('HOLD21_NAME').Value := HOLD21NAME;
        ParamByName('HOLD22_CODE').Value := HOLD22CODE;
        ParamByName('HOLD22_NAME').Value := HOLD22NAME;
        ParamByName('HOLD23_CODE').Value := HOLD23CODE;
        ParamByName('HOLD23_NAME').Value := HOLD23NAME;
        ParamByName('HOLD24_CODE').Value := HOLD24CODE;
        ParamByName('HOLD24_NAME').Value := HOLD24NAME;
        ParamByName('HOLD25_CODE').Value := HOLD25CODE;
        ParamByName('HOLD25_NAME').Value := HOLD25NAME;
        ParamByName('HOLD26_CODE').Value := HOLD26CODE;
        ParamByName('HOLD26_NAME').Value := HOLD26NAME;
        ParamByName('HOLD27_CODE').Value := HOLD27CODE;
        ParamByName('HOLD27_NAME').Value := HOLD27NAME;
        ParamByName('HOLD28_CODE').Value := HOLD28CODE;
        ParamByName('HOLD28_NAME').Value := HOLD28NAME;
        ParamByName('HOLD29_CODE').Value := HOLD29CODE;
        ParamByName('HOLD29_NAME').Value := HOLD29NAME;
        ParamByName('HOLD30_CODE').Value := HOLD30CODE;
        ParamByName('HOLD30_NAME').Value := HOLD30NAME;
        ParamByName('BIS_CODE').Value := BISCODE;
        ParamByName('BIS_NAME').Value := BISNAME;
        ParamByName('INPM_CODE').Value := INPMCODE;
        ParamByName('INPM_NAME').Value := INPMNAME;
        ParamByName('ST_CODE').Value := STCODE;
        ParamByName('ST_NAME').Value := STNAME;
        ParamByName('CT_CODE').Value := CTCODE;
        ParamByName('CT_NAME').Value := CTNAME;
        ParamByName('SM_CODE').Value := SMCODE;
        ParamByName('SM_NAME').Value := SMNAME;
        ParamByName('OPUSER_CODE').Value := OPUSERCODE;
        ParamByName('OPUSER_NAME').Value := OPUSERNAME;
        ParamByName('EDITOR_CODE').Value := EDITORCODE;
        ParamByName('EDITOR_NAME').Value := EDITORNAME;
        ParamByName('GB_CODE').Value := GBCODE;
        ParamByName('GB_NAME').Value := GBNAME;
        ParamByName('FM_CODE').Value := FMCODE;
        ParamByName('FM_NAME').Value := FMNAME;
        ParamByName('PAY_ACCOUNT_NO').Value := PAYACCOUNTNO;
        ParamByName('PAY_ACCOUNT_NAME').Value := PAYACCOUNTNAME;
        ParamByName('PAY_ACCOUNT_BANK').Value := PAYACCOUNTBANK;
        ParamByName('CLEAR_ACCOUNT_NO').Value := CLEARACCOUNTNO;
        ParamByName('CLEAR_ACCOUNT_NAME').Value := CLEARACCOUNTNAME;
        ParamByName('CLEAR_ACCOUNT_BANK').Value := CLEARACCOUNTBANK;
        ParamByName('INCOME_ACCOUNT_NO').Value := INCOMEACCOUNTNO;
        ParamByName('INCOME_ACCOUNT_NAME').Value := INCOMEACCOUNTNAME;
        ParamByName('INCOME_ACCOUNT_BANK').Value := INCOMEACCOUNTBANK;
        ParamByName('PF_ID').Value := PFID;
        ParamByName('PF_CODE').Value := PFCODE;
        ParamByName('PF_NAME').Value := PFNAME;
        ParamByName('GROUPID_ID').Value := GROUPIDID;
        ParamByName('GROUPID_CODE').Value := GROUPIDCODE;
        ParamByName('GROUPID_NAME').Value := GROUPIDNAME;
        ParamByName('USEEN_ID').Value := USEENID;
        ParamByName('USEEN_CODE').Value := USEENCODE;
        ParamByName('USEEN_NAME').Value := USEENNAME;
        ParamByName('PROV_ID').Value := PROVID;
        ParamByName('PROV_CODE').Value := PROVCODE;
        ParamByName('PROV_NAME').Value := PROVNAME;
        ParamByName('AGENCY_ID').Value := AGENCYID;
        ParamByName('AGENCY_CODE').Value := AGENCYCODE;
        ParamByName('AGENCY_NAME').Value := AGENCYNAME;
        ParamByName('MODE_ID').Value := MODEID;
        ParamByName('MODE_CODE').Value := MODECODE;
        ParamByName('MODE_NAME').Value := MODENAME;
        ParamByName('FASN_ID').Value := FASNID;
        ParamByName('FASN_CODE').Value := FASNCODE;
        ParamByName('FASN_NAME').Value := FASNNAME;
        ParamByName('DIR_ID').Value := DIRID;
        ParamByName('DIR_CODE').Value := DIRCODE;
        ParamByName('DIR_NAME').Value := DIRNAME;
        ParamByName('GPPLAN_ID').Value := GPPLANID;
        ParamByName('GPPLAN_CODE').Value := GPPLANCODE;
        ParamByName('GPPLAN_NAME').Value := GPPLANNAME;
        ParamByName('GPBARN_ID').Value := GPBARNID;
        ParamByName('GPBARN_CODE').Value := GPBARNCODE;
        ParamByName('GPBARN_NAME').Value := GPBARNNAME;
        ParamByName('WA_ID').Value := WAID;
        ParamByName('WA_CODE').Value := WACODE;
        ParamByName('WA_NAME').Value := WANAME;
        ParamByName('FF_ID').Value := FFID;
        ParamByName('FF_NAME').Value := FFNAME;
        ParamByName('FF_CODE').Value := FFCODE;
        ParamByName('IEN_ID').Value := IENID;
        ParamByName('IEN_NAME').Value := IENNAME;
        ParamByName('IEN_CODE').Value := IENCODE;
        ParamByName('SALTAG_ID').Value := SALTAGID;
        ParamByName('SALTAG_NAME').Value := SALTAGNAME;
        ParamByName('SALTAG_CODE').Value := SALTAGCODE;
        ParamByName('BC_ID').Value := BCID;
        ParamByName('BC_CODE').Value := BCCODE;
        ParamByName('BC_NAME').Value := BCNAME;
        ParamByName('BSO_ID').Value := BSOID;
        ParamByName('BSO_CODE').Value := BSOCODE;
        ParamByName('BSO_NAME').Value := BSONAME;
        ParamByName('AE_ID').Value := AEID;
        ParamByName('AE_CODE').Value := AECODE;
        ParamByName('AE_NAME').Value := AENAME;
        ParamByName('CCID').Value := CCID;
        ParamByName('BUDGET_VOU_ID').Value := BUDGETVOUID;
        ParamByName('BUDGET_VOU_CODE').Value := BUDGETVOUCODE;
        ParamByName('BUDGET_VOU_NAME').Value := BUDGETVOUNAME;
        ParamByName('MD5').Value := MD5;
        ParamByName('GP_VOU_ID').Value := GPVOUID;
        ParamByName('GP_VOU_CODE').Value := GPVOUCODE;
        ParamByName('GP_VOU_NAME').Value := GPVOUNAME; 
      end;
      otEdit:
      begin
        ParamByName('LATEST_OP_DATE').Value := LATESTOPDATE;
        ParamByName('LATEST_OP_USER').Value := LATESTOPUSER;
        ParamByName('COA_ID').Value := COAID;
        ParamByName('AS_ID').Value := ASID;
        ParamByName('EN_ID').Value := ENID;
        ParamByName('MK_ID').Value := MKID;
        ParamByName('BS_ID').Value := BSID;
        ParamByName('BI_ID').Value := BIID;
        ParamByName('BSI_ID').Value := BSIID;
        ParamByName('PK_ID').Value := PKID;
        ParamByName('BO_ID').Value := BOID;
        ParamByName('BK_ID').Value := BKID;
        ParamByName('MB_ID').Value := MBID;
        ParamByName('FILE_ID').Value := FILEID;
        ParamByName('PM_ID').Value := PMID;
        ParamByName('IN_BS_ID').Value := INBSID;
        ParamByName('IN_BIS_ID').Value := INBISID;
        ParamByName('CB_ID').Value := CBID;
        ParamByName('PB_ID').Value := PBID;
        ParamByName('IB_ID').Value := IBID;
        ParamByName('BAC_ID').Value := BACID;
        ParamByName('BAP_ID').Value := BAPID;
        ParamByName('BAI_ID').Value := BAIID;
        ParamByName('BT_ID').Value := BTID;
        ParamByName('BP_ID').Value := BPID;
        ParamByName('BL_ID').Value := BLID;
        ParamByName('HOLD1_ID').Value := HOLD1ID;
        ParamByName('HOLD2_ID').Value := HOLD2ID;
        ParamByName('HOLD3_ID').Value := HOLD3ID;
        ParamByName('HOLD4_ID').Value := HOLD4ID;
        ParamByName('HOLD5_ID').Value := HOLD5ID;
        ParamByName('HOLD6_ID').Value := HOLD6ID;
        ParamByName('HOLD7_ID').Value := HOLD7ID;
        ParamByName('HOLD8_ID').Value := HOLD8ID;
        ParamByName('HOLD9_ID').Value := HOLD9ID;
        ParamByName('HOLD10_ID').Value := HOLD10ID;
        ParamByName('HOLD11_ID').Value := HOLD11ID;
        ParamByName('HOLD12_ID').Value := HOLD12ID;
        ParamByName('HOLD13_ID').Value := HOLD13ID;
        ParamByName('HOLD14_ID').Value := HOLD14ID;
        ParamByName('HOLD15_ID').Value := HOLD15ID;
        ParamByName('HOLD16_ID').Value := HOLD16ID;
        ParamByName('HOLD17_ID').Value := HOLD17ID;
        ParamByName('HOLD18_ID').Value := HOLD18ID;
        ParamByName('HOLD19_ID').Value := HOLD19ID;
        ParamByName('HOLD20_ID').Value := HOLD20ID;
        ParamByName('HOLD21_ID').Value := HOLD21ID;
        ParamByName('HOLD22_ID').Value := HOLD22ID;
        ParamByName('HOLD23_ID').Value := HOLD23ID;
        ParamByName('HOLD24_ID').Value := HOLD24ID;
        ParamByName('HOLD25_ID').Value := HOLD25ID;
        ParamByName('HOLD26_ID').Value := HOLD26ID;
        ParamByName('HOLD27_ID').Value := HOLD27ID;
        ParamByName('HOLD28_ID').Value := HOLD28ID;
        ParamByName('HOLD29_ID').Value := HOLD29ID;
        ParamByName('HOLD30_ID').Value := HOLD30ID;
        ParamByName('SET_YEAR').Value := SETYEAR;
        ParamByName('BIS_ID').Value := BISID;
        ParamByName('INPM_ID').Value := INPMID;
        ParamByName('ST_ID').Value := STID;
        ParamByName('CT_ID').Value := CTID;
        ParamByName('SM_ID').Value := SMID;
        ParamByName('OPUSER_ID').Value := OPUSERID;
        ParamByName('EDITOR_ID').Value := EDITORID;
        ParamByName('GB_ID').Value := GBID;
        ParamByName('FM_ID').Value := FMID;
        ParamByName('AS_CODE').Value := ASCODE;
        ParamByName('AS_NAME').Value := ASNAME;
        ParamByName('EN_CODE').Value := ENCODE;
        ParamByName('EN_NAME').Value := ENNAME;
        ParamByName('MK_CODE').Value := MKCODE;
        ParamByName('MK_NAME').Value := MKNAME;
        ParamByName('BS_CODE').Value := BSCODE;
        ParamByName('BS_NAME').Value := BSNAME;
        ParamByName('BI_CODE').Value := BICODE;
        ParamByName('BI_NAME').Value := BINAME;
        ParamByName('BSI_CODE').Value := BSICODE;
        ParamByName('BSI_NAME').Value := BSINAME;
        ParamByName('PK_CODE').Value := PKCODE;
        ParamByName('PK_NAME').Value := PKNAME;
        ParamByName('BO_CODE').Value := BOCODE;
        ParamByName('BO_NAME').Value := BONAME;
        ParamByName('BK_CODE').Value := BKCODE;
        ParamByName('BK_NAME').Value := BKNAME;
        ParamByName('MB_CODE').Value := MBCODE;
        ParamByName('MB_NAME').Value := MBNAME;
        ParamByName('FILE_CODE').Value := FILECODE;
        ParamByName('FILE_NAME').Value := FILENAME;
        ParamByName('PM_CODE').Value := PMCODE;
        ParamByName('PM_NAME').Value := PMNAME;
        ParamByName('IN_BS_CODE').Value := INBSCODE;
        ParamByName('IN_BS_NAME').Value := INBSNAME;
        ParamByName('IN_BIS_CODE').Value := INBISCODE;
        ParamByName('IN_BIS_NAME').Value := INBISNAME;
        ParamByName('CB_CODE').Value := CBCODE;
        ParamByName('CB_NAME').Value := CBNAME;
        ParamByName('PB_CODE').Value := PBCODE;
        ParamByName('PB_NAME').Value := PBNAME;
        ParamByName('IB_CODE').Value := IBCODE;
        ParamByName('IB_NAME').Value := IBNAME;
        ParamByName('BAC_CODE').Value := BACCODE;
        ParamByName('BAC_NAME').Value := BACNAME;
        ParamByName('BAP_CODE').Value := BAPCODE;
        ParamByName('BAP_NAME').Value := BAPNAME;
        ParamByName('BAI_CODE').Value := BAICODE;
        ParamByName('BAI_NAME').Value := BAINAME;
        ParamByName('BT_CODE').Value := BTCODE;
        ParamByName('BT_NAME').Value := BTNAME;
        ParamByName('BP_CODE').Value := BPCODE;
        ParamByName('BP_NAME').Value := BPNAME;
        ParamByName('BL_CODE').Value := BLCODE;
        ParamByName('BL_NAME').Value := BLNAME;
        ParamByName('HOLD1_CODE').Value := HOLD1CODE;
        ParamByName('HOLD1_NAME').Value := HOLD1NAME;
        ParamByName('HOLD2_CODE').Value := HOLD2CODE;
        ParamByName('HOLD2_NAME').Value := HOLD2NAME;
        ParamByName('HOLD3_CODE').Value := HOLD3CODE;
        ParamByName('HOLD3_NAME').Value := HOLD3NAME;
        ParamByName('HOLD4_CODE').Value := HOLD4CODE;
        ParamByName('HOLD4_NAME').Value := HOLD4NAME;
        ParamByName('HOLD5_CODE').Value := HOLD5CODE;
        ParamByName('HOLD5_NAME').Value := HOLD5NAME;
        ParamByName('HOLD6_CODE').Value := HOLD6CODE;
        ParamByName('HOLD6_NAME').Value := HOLD6NAME;
        ParamByName('HOLD7_CODE').Value := HOLD7CODE;
        ParamByName('HOLD7_NAME').Value := HOLD7NAME;
        ParamByName('HOLD8_CODE').Value := HOLD8CODE;
        ParamByName('HOLD8_NAME').Value := HOLD8NAME;
        ParamByName('HOLD9_CODE').Value := HOLD9CODE;
        ParamByName('HOLD9_NAME').Value := HOLD9NAME;
        ParamByName('HOLD10_CODE').Value := HOLD10CODE;
        ParamByName('HOLD10_NAME').Value := HOLD10NAME;
        ParamByName('HOLD11_CODE').Value := HOLD11CODE;
        ParamByName('HOLD11_NAME').Value := HOLD11NAME;
        ParamByName('HOLD12_CODE').Value := HOLD12CODE;
        ParamByName('HOLD12_NAME').Value := HOLD12NAME;
        ParamByName('HOLD13_CODE').Value := HOLD13CODE;
        ParamByName('HOLD13_NAME').Value := HOLD13NAME;
        ParamByName('HOLD14_CODE').Value := HOLD14CODE;
        ParamByName('HOLD14_NAME').Value := HOLD14NAME;
        ParamByName('HOLD15_CODE').Value := HOLD15CODE;
        ParamByName('HOLD15_NAME').Value := HOLD15NAME;
        ParamByName('HOLD16_CODE').Value := HOLD16CODE;
        ParamByName('HOLD16_NAME').Value := HOLD16NAME;
        ParamByName('HOLD17_CODE').Value := HOLD17CODE;
        ParamByName('HOLD17_NAME').Value := HOLD17NAME;
        ParamByName('HOLD18_CODE').Value := HOLD18CODE;
        ParamByName('HOLD18_NAME').Value := HOLD18NAME;
        ParamByName('HOLD19_CODE').Value := HOLD19CODE;
        ParamByName('HOLD19_NAME').Value := HOLD19NAME;
        ParamByName('HOLD20_CODE').Value := HOLD20CODE;
        ParamByName('HOLD20_NAME').Value := HOLD20NAME;
        ParamByName('HOLD21_CODE').Value := HOLD21CODE;
        ParamByName('HOLD21_NAME').Value := HOLD21NAME;
        ParamByName('HOLD22_CODE').Value := HOLD22CODE;
        ParamByName('HOLD22_NAME').Value := HOLD22NAME;
        ParamByName('HOLD23_CODE').Value := HOLD23CODE;
        ParamByName('HOLD23_NAME').Value := HOLD23NAME;
        ParamByName('HOLD24_CODE').Value := HOLD24CODE;
        ParamByName('HOLD24_NAME').Value := HOLD24NAME;
        ParamByName('HOLD25_CODE').Value := HOLD25CODE;
        ParamByName('HOLD25_NAME').Value := HOLD25NAME;
        ParamByName('HOLD26_CODE').Value := HOLD26CODE;
        ParamByName('HOLD26_NAME').Value := HOLD26NAME;
        ParamByName('HOLD27_CODE').Value := HOLD27CODE;
        ParamByName('HOLD27_NAME').Value := HOLD27NAME;
        ParamByName('HOLD28_CODE').Value := HOLD28CODE;
        ParamByName('HOLD28_NAME').Value := HOLD28NAME;
        ParamByName('HOLD29_CODE').Value := HOLD29CODE;
        ParamByName('HOLD29_NAME').Value := HOLD29NAME;
        ParamByName('HOLD30_CODE').Value := HOLD30CODE;
        ParamByName('HOLD30_NAME').Value := HOLD30NAME;
        ParamByName('BIS_CODE').Value := BISCODE;
        ParamByName('BIS_NAME').Value := BISNAME;
        ParamByName('INPM_CODE').Value := INPMCODE;
        ParamByName('INPM_NAME').Value := INPMNAME;
        ParamByName('ST_CODE').Value := STCODE;
        ParamByName('ST_NAME').Value := STNAME;
        ParamByName('CT_CODE').Value := CTCODE;
        ParamByName('CT_NAME').Value := CTNAME;
        ParamByName('SM_CODE').Value := SMCODE;
        ParamByName('SM_NAME').Value := SMNAME;
        ParamByName('OPUSER_CODE').Value := OPUSERCODE;
        ParamByName('OPUSER_NAME').Value := OPUSERNAME;
        ParamByName('EDITOR_CODE').Value := EDITORCODE;
        ParamByName('EDITOR_NAME').Value := EDITORNAME;
        ParamByName('GB_CODE').Value := GBCODE;
        ParamByName('GB_NAME').Value := GBNAME;
        ParamByName('FM_CODE').Value := FMCODE;
        ParamByName('FM_NAME').Value := FMNAME;
        ParamByName('PAY_ACCOUNT_NO').Value := PAYACCOUNTNO;
        ParamByName('PAY_ACCOUNT_NAME').Value := PAYACCOUNTNAME;
        ParamByName('PAY_ACCOUNT_BANK').Value := PAYACCOUNTBANK;
        ParamByName('CLEAR_ACCOUNT_NO').Value := CLEARACCOUNTNO;
        ParamByName('CLEAR_ACCOUNT_NAME').Value := CLEARACCOUNTNAME;
        ParamByName('CLEAR_ACCOUNT_BANK').Value := CLEARACCOUNTBANK;
        ParamByName('INCOME_ACCOUNT_NO').Value := INCOMEACCOUNTNO;
        ParamByName('INCOME_ACCOUNT_NAME').Value := INCOMEACCOUNTNAME;
        ParamByName('INCOME_ACCOUNT_BANK').Value := INCOMEACCOUNTBANK;
        ParamByName('PF_ID').Value := PFID;
        ParamByName('PF_CODE').Value := PFCODE;
        ParamByName('PF_NAME').Value := PFNAME;
        ParamByName('GROUPID_ID').Value := GROUPIDID;
        ParamByName('GROUPID_CODE').Value := GROUPIDCODE;
        ParamByName('GROUPID_NAME').Value := GROUPIDNAME;
        ParamByName('USEEN_ID').Value := USEENID;
        ParamByName('USEEN_CODE').Value := USEENCODE;
        ParamByName('USEEN_NAME').Value := USEENNAME;
        ParamByName('PROV_ID').Value := PROVID;
        ParamByName('PROV_CODE').Value := PROVCODE;
        ParamByName('PROV_NAME').Value := PROVNAME;
        ParamByName('AGENCY_ID').Value := AGENCYID;
        ParamByName('AGENCY_CODE').Value := AGENCYCODE;
        ParamByName('AGENCY_NAME').Value := AGENCYNAME;
        ParamByName('MODE_ID').Value := MODEID;
        ParamByName('MODE_CODE').Value := MODECODE;
        ParamByName('MODE_NAME').Value := MODENAME;
        ParamByName('FASN_ID').Value := FASNID;
        ParamByName('FASN_CODE').Value := FASNCODE;
        ParamByName('FASN_NAME').Value := FASNNAME;
        ParamByName('DIR_ID').Value := DIRID;
        ParamByName('DIR_CODE').Value := DIRCODE;
        ParamByName('DIR_NAME').Value := DIRNAME;
        ParamByName('GPPLAN_ID').Value := GPPLANID;
        ParamByName('GPPLAN_CODE').Value := GPPLANCODE;
        ParamByName('GPPLAN_NAME').Value := GPPLANNAME;
        ParamByName('GPBARN_ID').Value := GPBARNID;
        ParamByName('GPBARN_CODE').Value := GPBARNCODE;
        ParamByName('GPBARN_NAME').Value := GPBARNNAME;
        ParamByName('WA_ID').Value := WAID;
        ParamByName('WA_CODE').Value := WACODE;
        ParamByName('WA_NAME').Value := WANAME;
        ParamByName('FF_ID').Value := FFID;
        ParamByName('FF_NAME').Value := FFNAME;
        ParamByName('FF_CODE').Value := FFCODE;
        ParamByName('IEN_ID').Value := IENID;
        ParamByName('IEN_NAME').Value := IENNAME;
        ParamByName('IEN_CODE').Value := IENCODE;
        ParamByName('SALTAG_ID').Value := SALTAGID;
        ParamByName('SALTAG_NAME').Value := SALTAGNAME;
        ParamByName('SALTAG_CODE').Value := SALTAGCODE;
        ParamByName('BC_ID').Value := BCID;
        ParamByName('BC_CODE').Value := BCCODE;
        ParamByName('BC_NAME').Value := BCNAME;
        ParamByName('BSO_ID').Value := BSOID;
        ParamByName('BSO_CODE').Value := BSOCODE;
        ParamByName('BSO_NAME').Value := BSONAME;
        ParamByName('AE_ID').Value := AEID;
        ParamByName('AE_CODE').Value := AECODE;
        ParamByName('AE_NAME').Value := AENAME;
        ParamByName('CCID').Value := CCID;
        ParamByName('BUDGET_VOU_ID').Value := BUDGETVOUID;
        ParamByName('BUDGET_VOU_CODE').Value := BUDGETVOUCODE;
        ParamByName('BUDGET_VOU_NAME').Value := BUDGETVOUNAME;
        ParamByName('MD5').Value := MD5;
        ParamByName('GP_VOU_ID').Value := GPVOUID;
        ParamByName('GP_VOU_CODE').Value := GPVOUCODE;
        ParamByName('GP_VOU_NAME').Value := GPVOUNAME; 
      end;  
      otDelt:
      begin
        ParamByName('EN_ID').Value := ENID;
        ParamByName('CCID').Value := CCID;
 
      end;  
    end;
  end;
end;

function TGLCCIDS.CheckExist(AUniConnection: TUniConnection): Boolean;
begin
  Result:=CheckExist('GL_CCIDS',['EN_ID',ENID,'CCID',CCID],AUniConnection);
end;

function TGLCCIDS.GetNextIdex: Integer;
begin

end;

function TGLCCIDS.GetNextIdex(AUniConnection: TUniConnection): Integer;
begin

end;

function TGLCCIDS.GetStrDelete: string;
begin
  Result:='DELETE FROM GL_CCIDS WHERE   EN_ID=:EN_ID AND CCID=:CCID';
end;

function TGLCCIDS.GetStrInsert: string;
begin
  Result:='INSERT INTO GL_CCIDS'
         +'    ( LATEST_OP_DATE, LATEST_OP_USER, COA_ID, AS_ID, EN_ID'
         +'    , MK_ID, BS_ID, BI_ID, BSI_ID, PK_ID, BO_ID, BK_ID, MB_ID'
         +'    , FILE_ID, PM_ID, IN_BS_ID, IN_BIS_ID, CB_ID, PB_ID'
         +'    , IB_ID, BAC_ID, BAP_ID, BAI_ID, BT_ID, BP_ID, BL_ID'
         +'    , HOLD1_ID, HOLD2_ID, HOLD3_ID, HOLD4_ID, HOLD5_ID, HOLD6_ID'
         +'    , HOLD7_ID, HOLD8_ID, HOLD9_ID, HOLD10_ID, HOLD11_ID'
         +'    , HOLD12_ID, HOLD13_ID, HOLD14_ID, HOLD15_ID, HOLD16_ID'
         +'    , HOLD17_ID, HOLD18_ID, HOLD19_ID, HOLD20_ID, HOLD21_ID'
         +'    , HOLD22_ID, HOLD23_ID, HOLD24_ID, HOLD25_ID, HOLD26_ID'
         +'    , HOLD27_ID, HOLD28_ID, HOLD29_ID, HOLD30_ID, SET_YEAR'
         +'    , BIS_ID, INPM_ID, ST_ID, CT_ID, SM_ID, OPUSER_ID, EDITOR_ID'
         +'    , GB_ID, FM_ID, AS_CODE, AS_NAME, EN_CODE, EN_NAME, MK_CODE'
         +'    , MK_NAME, BS_CODE, BS_NAME, BI_CODE, BI_NAME, BSI_CODE'
         +'    , BSI_NAME, PK_CODE, PK_NAME, BO_CODE, BO_NAME, BK_CODE'
         +'    , BK_NAME, MB_CODE, MB_NAME, FILE_CODE, FILE_NAME, PM_CODE'
         +'    , PM_NAME, IN_BS_CODE, IN_BS_NAME, IN_BIS_CODE, IN_BIS_NAME'
         +'    , CB_CODE, CB_NAME, PB_CODE, PB_NAME, IB_CODE, IB_NAME'
         +'    , BAC_CODE, BAC_NAME, BAP_CODE, BAP_NAME, BAI_CODE, BAI_NAME'
         +'    , BT_CODE, BT_NAME, BP_CODE, BP_NAME, BL_CODE, BL_NAME'
         +'    , HOLD1_CODE, HOLD1_NAME, HOLD2_CODE, HOLD2_NAME, HOLD3_CODE'
         +'    , HOLD3_NAME, HOLD4_CODE, HOLD4_NAME, HOLD5_CODE, HOLD5_NAME'
         +'    , HOLD6_CODE, HOLD6_NAME, HOLD7_CODE, HOLD7_NAME, HOLD8_CODE'
         +'    , HOLD8_NAME, HOLD9_CODE, HOLD9_NAME, HOLD10_CODE, HOLD10_NAME'
         +'    , HOLD11_CODE, HOLD11_NAME, HOLD12_CODE, HOLD12_NAME'
         +'    , HOLD13_CODE, HOLD13_NAME, HOLD14_CODE, HOLD14_NAME'
         +'    , HOLD15_CODE, HOLD15_NAME, HOLD16_CODE, HOLD16_NAME'
         +'    , HOLD17_CODE, HOLD17_NAME, HOLD18_CODE, HOLD18_NAME'
         +'    , HOLD19_CODE, HOLD19_NAME, HOLD20_CODE, HOLD20_NAME'
         +'    , HOLD21_CODE, HOLD21_NAME, HOLD22_CODE, HOLD22_NAME'
         +'    , HOLD23_CODE, HOLD23_NAME, HOLD24_CODE, HOLD24_NAME'
         +'    , HOLD25_CODE, HOLD25_NAME, HOLD26_CODE, HOLD26_NAME'
         +'    , HOLD27_CODE, HOLD27_NAME, HOLD28_CODE, HOLD28_NAME'
         +'    , HOLD29_CODE, HOLD29_NAME, HOLD30_CODE, HOLD30_NAME'
         +'    , BIS_CODE, BIS_NAME, INPM_CODE, INPM_NAME, ST_CODE'
         +'    , ST_NAME, CT_CODE, CT_NAME, SM_CODE, SM_NAME, OPUSER_CODE'
         +'    , OPUSER_NAME, EDITOR_CODE, EDITOR_NAME, GB_CODE, GB_NAME'
         +'    , FM_CODE, FM_NAME, PAY_ACCOUNT_NO, PAY_ACCOUNT_NAME'
         +'    , PAY_ACCOUNT_BANK, CLEAR_ACCOUNT_NO, CLEAR_ACCOUNT_NAME'
         +'    , CLEAR_ACCOUNT_BANK, INCOME_ACCOUNT_NO, INCOME_ACCOUNT_NAME'
         +'    , INCOME_ACCOUNT_BANK, PF_ID, PF_CODE, PF_NAME, GROUPID_ID'
         +'    , GROUPID_CODE, GROUPID_NAME, USEEN_ID, USEEN_CODE, USEEN_NAME'
         +'    , PROV_ID, PROV_CODE, PROV_NAME, AGENCY_ID, AGENCY_CODE'
         +'    , AGENCY_NAME, MODE_ID, MODE_CODE, MODE_NAME, FASN_ID'
         +'    , FASN_CODE, FASN_NAME, DIR_ID, DIR_CODE, DIR_NAME, GPPLAN_ID'
         +'    , GPPLAN_CODE, GPPLAN_NAME, GPBARN_ID, GPBARN_CODE, GPBARN_NAME'
         +'    , WA_ID, WA_CODE, WA_NAME, FF_ID, FF_NAME, FF_CODE, IEN_ID'
         +'    , IEN_NAME, IEN_CODE, SALTAG_ID, SALTAG_NAME, SALTAG_CODE'
         +'    , BC_ID, BC_CODE, BC_NAME, BSO_ID, BSO_CODE, BSO_NAME'
         +'    , AE_ID, AE_CODE, AE_NAME, CCID, BUDGET_VOU_ID, BUDGET_VOU_CODE'
         +'    , BUDGET_VOU_NAME, MD5, GP_VOU_ID, GP_VOU_CODE, GP_VOU_NAME)'
         +'    VALUES'
         +'    (:LATEST_OP_DATE,:LATEST_OP_USER,:COA_ID,:AS_ID,:EN_ID'
         +'    ,:MK_ID,:BS_ID,:BI_ID,:BSI_ID,:PK_ID,:BO_ID,:BK_ID,:MB_ID'
         +'    ,:FILE_ID,:PM_ID,:IN_BS_ID,:IN_BIS_ID,:CB_ID,:PB_ID'
         +'    ,:IB_ID,:BAC_ID,:BAP_ID,:BAI_ID,:BT_ID,:BP_ID,:BL_ID'
         +'    ,:HOLD1_ID,:HOLD2_ID,:HOLD3_ID,:HOLD4_ID,:HOLD5_ID,:HOLD6_ID'
         +'    ,:HOLD7_ID,:HOLD8_ID,:HOLD9_ID,:HOLD10_ID,:HOLD11_ID'
         +'    ,:HOLD12_ID,:HOLD13_ID,:HOLD14_ID,:HOLD15_ID,:HOLD16_ID'
         +'    ,:HOLD17_ID,:HOLD18_ID,:HOLD19_ID,:HOLD20_ID,:HOLD21_ID'
         +'    ,:HOLD22_ID,:HOLD23_ID,:HOLD24_ID,:HOLD25_ID,:HOLD26_ID'
         +'    ,:HOLD27_ID,:HOLD28_ID,:HOLD29_ID,:HOLD30_ID,:SET_YEAR'
         +'    ,:BIS_ID,:INPM_ID,:ST_ID,:CT_ID,:SM_ID,:OPUSER_ID,:EDITOR_ID'
         +'    ,:GB_ID,:FM_ID,:AS_CODE,:AS_NAME,:EN_CODE,:EN_NAME,:MK_CODE'
         +'    ,:MK_NAME,:BS_CODE,:BS_NAME,:BI_CODE,:BI_NAME,:BSI_CODE'
         +'    ,:BSI_NAME,:PK_CODE,:PK_NAME,:BO_CODE,:BO_NAME,:BK_CODE'
         +'    ,:BK_NAME,:MB_CODE,:MB_NAME,:FILE_CODE,:FILE_NAME,:PM_CODE'
         +'    ,:PM_NAME,:IN_BS_CODE,:IN_BS_NAME,:IN_BIS_CODE,:IN_BIS_NAME'
         +'    ,:CB_CODE,:CB_NAME,:PB_CODE,:PB_NAME,:IB_CODE,:IB_NAME'
         +'    ,:BAC_CODE,:BAC_NAME,:BAP_CODE,:BAP_NAME,:BAI_CODE,:BAI_NAME'
         +'    ,:BT_CODE,:BT_NAME,:BP_CODE,:BP_NAME,:BL_CODE,:BL_NAME'
         +'    ,:HOLD1_CODE,:HOLD1_NAME,:HOLD2_CODE,:HOLD2_NAME,:HOLD3_CODE'
         +'    ,:HOLD3_NAME,:HOLD4_CODE,:HOLD4_NAME,:HOLD5_CODE,:HOLD5_NAME'
         +'    ,:HOLD6_CODE,:HOLD6_NAME,:HOLD7_CODE,:HOLD7_NAME,:HOLD8_CODE'
         +'    ,:HOLD8_NAME,:HOLD9_CODE,:HOLD9_NAME,:HOLD10_CODE,:HOLD10_NAME'
         +'    ,:HOLD11_CODE,:HOLD11_NAME,:HOLD12_CODE,:HOLD12_NAME'
         +'    ,:HOLD13_CODE,:HOLD13_NAME,:HOLD14_CODE,:HOLD14_NAME'
         +'    ,:HOLD15_CODE,:HOLD15_NAME,:HOLD16_CODE,:HOLD16_NAME'
         +'    ,:HOLD17_CODE,:HOLD17_NAME,:HOLD18_CODE,:HOLD18_NAME'
         +'    ,:HOLD19_CODE,:HOLD19_NAME,:HOLD20_CODE,:HOLD20_NAME'
         +'    ,:HOLD21_CODE,:HOLD21_NAME,:HOLD22_CODE,:HOLD22_NAME'
         +'    ,:HOLD23_CODE,:HOLD23_NAME,:HOLD24_CODE,:HOLD24_NAME'
         +'    ,:HOLD25_CODE,:HOLD25_NAME,:HOLD26_CODE,:HOLD26_NAME'
         +'    ,:HOLD27_CODE,:HOLD27_NAME,:HOLD28_CODE,:HOLD28_NAME'
         +'    ,:HOLD29_CODE,:HOLD29_NAME,:HOLD30_CODE,:HOLD30_NAME'
         +'    ,:BIS_CODE,:BIS_NAME,:INPM_CODE,:INPM_NAME,:ST_CODE'
         +'    ,:ST_NAME,:CT_CODE,:CT_NAME,:SM_CODE,:SM_NAME,:OPUSER_CODE'
         +'    ,:OPUSER_NAME,:EDITOR_CODE,:EDITOR_NAME,:GB_CODE,:GB_NAME'
         +'    ,:FM_CODE,:FM_NAME,:PAY_ACCOUNT_NO,:PAY_ACCOUNT_NAME'
         +'    ,:PAY_ACCOUNT_BANK,:CLEAR_ACCOUNT_NO,:CLEAR_ACCOUNT_NAME'
         +'    ,:CLEAR_ACCOUNT_BANK,:INCOME_ACCOUNT_NO,:INCOME_ACCOUNT_NAME'
         +'    ,:INCOME_ACCOUNT_BANK,:PF_ID,:PF_CODE,:PF_NAME,:GROUPID_ID'
         +'    ,:GROUPID_CODE,:GROUPID_NAME,:USEEN_ID,:USEEN_CODE,:USEEN_NAME'
         +'    ,:PROV_ID,:PROV_CODE,:PROV_NAME,:AGENCY_ID,:AGENCY_CODE'
         +'    ,:AGENCY_NAME,:MODE_ID,:MODE_CODE,:MODE_NAME,:FASN_ID'
         +'    ,:FASN_CODE,:FASN_NAME,:DIR_ID,:DIR_CODE,:DIR_NAME,:GPPLAN_ID'
         +'    ,:GPPLAN_CODE,:GPPLAN_NAME,:GPBARN_ID,:GPBARN_CODE,:GPBARN_NAME'
         +'    ,:WA_ID,:WA_CODE,:WA_NAME,:FF_ID,:FF_NAME,:FF_CODE,:IEN_ID'
         +'    ,:IEN_NAME,:IEN_CODE,:SALTAG_ID,:SALTAG_NAME,:SALTAG_CODE'
         +'    ,:BC_ID,:BC_CODE,:BC_NAME,:BSO_ID,:BSO_CODE,:BSO_NAME'
         +'    ,:AE_ID,:AE_CODE,:AE_NAME,:CCID,:BUDGET_VOU_ID,:BUDGET_VOU_CODE'
         +'    ,:BUDGET_VOU_NAME,:MD5,:GP_VOU_ID,:GP_VOU_CODE,:GP_VOU_NAME)';
end;

function TGLCCIDS.GetStrsIndex: string;
begin
  Result:=Format('%S',[ENID]);
end;

function TGLCCIDS.GetStrUpdate: string;
begin
  Result:='UPDATE  GL_CCIDS SET'
         +'    LATEST_OP_DATE=:LATEST_OP_DATE,'
         +'    LATEST_OP_USER=:LATEST_OP_USER,'
         +'    COA_ID=:COA_ID,'
         +'    AS_ID=:AS_ID,'
         +'    MK_ID=:MK_ID,'
         +'    BS_ID=:BS_ID,'
         +'    BI_ID=:BI_ID,'
         +'    BSI_ID=:BSI_ID,'
         +'    PK_ID=:PK_ID,'
         +'    BO_ID=:BO_ID,'
         +'    BK_ID=:BK_ID,'
         +'    MB_ID=:MB_ID,'
         +'    FILE_ID=:FILE_ID,'
         +'    PM_ID=:PM_ID,'
         +'    IN_BS_ID=:IN_BS_ID,'
         +'    IN_BIS_ID=:IN_BIS_ID,'
         +'    CB_ID=:CB_ID,'
         +'    PB_ID=:PB_ID,'
         +'    IB_ID=:IB_ID,'
         +'    BAC_ID=:BAC_ID,'
         +'    BAP_ID=:BAP_ID,'
         +'    BAI_ID=:BAI_ID,'
         +'    BT_ID=:BT_ID,'
         +'    BP_ID=:BP_ID,'
         +'    BL_ID=:BL_ID,'
         +'    HOLD1_ID=:HOLD1_ID,'
         +'    HOLD2_ID=:HOLD2_ID,'
         +'    HOLD3_ID=:HOLD3_ID,'
         +'    HOLD4_ID=:HOLD4_ID,'
         +'    HOLD5_ID=:HOLD5_ID,'
         +'    HOLD6_ID=:HOLD6_ID,'
         +'    HOLD7_ID=:HOLD7_ID,'
         +'    HOLD8_ID=:HOLD8_ID,'
         +'    HOLD9_ID=:HOLD9_ID,'
         +'    HOLD10_ID=:HOLD10_ID,'
         +'    HOLD11_ID=:HOLD11_ID,'
         +'    HOLD12_ID=:HOLD12_ID,'
         +'    HOLD13_ID=:HOLD13_ID,'
         +'    HOLD14_ID=:HOLD14_ID,'
         +'    HOLD15_ID=:HOLD15_ID,'
         +'    HOLD16_ID=:HOLD16_ID,'
         +'    HOLD17_ID=:HOLD17_ID,'
         +'    HOLD18_ID=:HOLD18_ID,'
         +'    HOLD19_ID=:HOLD19_ID,'
         +'    HOLD20_ID=:HOLD20_ID,'
         +'    HOLD21_ID=:HOLD21_ID,'
         +'    HOLD22_ID=:HOLD22_ID,'
         +'    HOLD23_ID=:HOLD23_ID,'
         +'    HOLD24_ID=:HOLD24_ID,'
         +'    HOLD25_ID=:HOLD25_ID,'
         +'    HOLD26_ID=:HOLD26_ID,'
         +'    HOLD27_ID=:HOLD27_ID,'
         +'    HOLD28_ID=:HOLD28_ID,'
         +'    HOLD29_ID=:HOLD29_ID,'
         +'    HOLD30_ID=:HOLD30_ID,'
         +'    SET_YEAR=:SET_YEAR,'
         +'    BIS_ID=:BIS_ID,'
         +'    INPM_ID=:INPM_ID,'
         +'    ST_ID=:ST_ID,'
         +'    CT_ID=:CT_ID,'
         +'    SM_ID=:SM_ID,'
         +'    OPUSER_ID=:OPUSER_ID,'
         +'    EDITOR_ID=:EDITOR_ID,'
         +'    GB_ID=:GB_ID,'
         +'    FM_ID=:FM_ID,'
         +'    AS_CODE=:AS_CODE,'
         +'    AS_NAME=:AS_NAME,'
         +'    EN_CODE=:EN_CODE,'
         +'    EN_NAME=:EN_NAME,'
         +'    MK_CODE=:MK_CODE,'
         +'    MK_NAME=:MK_NAME,'
         +'    BS_CODE=:BS_CODE,'
         +'    BS_NAME=:BS_NAME,'
         +'    BI_CODE=:BI_CODE,'
         +'    BI_NAME=:BI_NAME,'
         +'    BSI_CODE=:BSI_CODE,'
         +'    BSI_NAME=:BSI_NAME,'
         +'    PK_CODE=:PK_CODE,'
         +'    PK_NAME=:PK_NAME,'
         +'    BO_CODE=:BO_CODE,'
         +'    BO_NAME=:BO_NAME,'
         +'    BK_CODE=:BK_CODE,'
         +'    BK_NAME=:BK_NAME,'
         +'    MB_CODE=:MB_CODE,'
         +'    MB_NAME=:MB_NAME,'
         +'    FILE_CODE=:FILE_CODE,'
         +'    FILE_NAME=:FILE_NAME,'
         +'    PM_CODE=:PM_CODE,'
         +'    PM_NAME=:PM_NAME,'
         +'    IN_BS_CODE=:IN_BS_CODE,'
         +'    IN_BS_NAME=:IN_BS_NAME,'
         +'    IN_BIS_CODE=:IN_BIS_CODE,'
         +'    IN_BIS_NAME=:IN_BIS_NAME,'
         +'    CB_CODE=:CB_CODE,'
         +'    CB_NAME=:CB_NAME,'
         +'    PB_CODE=:PB_CODE,'
         +'    PB_NAME=:PB_NAME,'
         +'    IB_CODE=:IB_CODE,'
         +'    IB_NAME=:IB_NAME,'
         +'    BAC_CODE=:BAC_CODE,'
         +'    BAC_NAME=:BAC_NAME,'
         +'    BAP_CODE=:BAP_CODE,'
         +'    BAP_NAME=:BAP_NAME,'
         +'    BAI_CODE=:BAI_CODE,'
         +'    BAI_NAME=:BAI_NAME,'
         +'    BT_CODE=:BT_CODE,'
         +'    BT_NAME=:BT_NAME,'
         +'    BP_CODE=:BP_CODE,'
         +'    BP_NAME=:BP_NAME,'
         +'    BL_CODE=:BL_CODE,'
         +'    BL_NAME=:BL_NAME,'
         +'    HOLD1_CODE=:HOLD1_CODE,'
         +'    HOLD1_NAME=:HOLD1_NAME,'
         +'    HOLD2_CODE=:HOLD2_CODE,'
         +'    HOLD2_NAME=:HOLD2_NAME,'
         +'    HOLD3_CODE=:HOLD3_CODE,'
         +'    HOLD3_NAME=:HOLD3_NAME,'
         +'    HOLD4_CODE=:HOLD4_CODE,'
         +'    HOLD4_NAME=:HOLD4_NAME,'
         +'    HOLD5_CODE=:HOLD5_CODE,'
         +'    HOLD5_NAME=:HOLD5_NAME,'
         +'    HOLD6_CODE=:HOLD6_CODE,'
         +'    HOLD6_NAME=:HOLD6_NAME,'
         +'    HOLD7_CODE=:HOLD7_CODE,'
         +'    HOLD7_NAME=:HOLD7_NAME,'
         +'    HOLD8_CODE=:HOLD8_CODE,'
         +'    HOLD8_NAME=:HOLD8_NAME,'
         +'    HOLD9_CODE=:HOLD9_CODE,'
         +'    HOLD9_NAME=:HOLD9_NAME,'
         +'    HOLD10_CODE=:HOLD10_CODE,'
         +'    HOLD10_NAME=:HOLD10_NAME,'
         +'    HOLD11_CODE=:HOLD11_CODE,'
         +'    HOLD11_NAME=:HOLD11_NAME,'
         +'    HOLD12_CODE=:HOLD12_CODE,'
         +'    HOLD12_NAME=:HOLD12_NAME,'
         +'    HOLD13_CODE=:HOLD13_CODE,'
         +'    HOLD13_NAME=:HOLD13_NAME,'
         +'    HOLD14_CODE=:HOLD14_CODE,'
         +'    HOLD14_NAME=:HOLD14_NAME,'
         +'    HOLD15_CODE=:HOLD15_CODE,'
         +'    HOLD15_NAME=:HOLD15_NAME,'
         +'    HOLD16_CODE=:HOLD16_CODE,'
         +'    HOLD16_NAME=:HOLD16_NAME,'
         +'    HOLD17_CODE=:HOLD17_CODE,'
         +'    HOLD17_NAME=:HOLD17_NAME,'
         +'    HOLD18_CODE=:HOLD18_CODE,'
         +'    HOLD18_NAME=:HOLD18_NAME,'
         +'    HOLD19_CODE=:HOLD19_CODE,'
         +'    HOLD19_NAME=:HOLD19_NAME,'
         +'    HOLD20_CODE=:HOLD20_CODE,'
         +'    HOLD20_NAME=:HOLD20_NAME,'
         +'    HOLD21_CODE=:HOLD21_CODE,'
         +'    HOLD21_NAME=:HOLD21_NAME,'
         +'    HOLD22_CODE=:HOLD22_CODE,'
         +'    HOLD22_NAME=:HOLD22_NAME,'
         +'    HOLD23_CODE=:HOLD23_CODE,'
         +'    HOLD23_NAME=:HOLD23_NAME,'
         +'    HOLD24_CODE=:HOLD24_CODE,'
         +'    HOLD24_NAME=:HOLD24_NAME,'
         +'    HOLD25_CODE=:HOLD25_CODE,'
         +'    HOLD25_NAME=:HOLD25_NAME,'
         +'    HOLD26_CODE=:HOLD26_CODE,'
         +'    HOLD26_NAME=:HOLD26_NAME,'
         +'    HOLD27_CODE=:HOLD27_CODE,'
         +'    HOLD27_NAME=:HOLD27_NAME,'
         +'    HOLD28_CODE=:HOLD28_CODE,'
         +'    HOLD28_NAME=:HOLD28_NAME,'
         +'    HOLD29_CODE=:HOLD29_CODE,'
         +'    HOLD29_NAME=:HOLD29_NAME,'
         +'    HOLD30_CODE=:HOLD30_CODE,'
         +'    HOLD30_NAME=:HOLD30_NAME,'
         +'    BIS_CODE=:BIS_CODE,'
         +'    BIS_NAME=:BIS_NAME,'
         +'    INPM_CODE=:INPM_CODE,'
         +'    INPM_NAME=:INPM_NAME,'
         +'    ST_CODE=:ST_CODE,'
         +'    ST_NAME=:ST_NAME,'
         +'    CT_CODE=:CT_CODE,'
         +'    CT_NAME=:CT_NAME,'
         +'    SM_CODE=:SM_CODE,'
         +'    SM_NAME=:SM_NAME,'
         +'    OPUSER_CODE=:OPUSER_CODE,'
         +'    OPUSER_NAME=:OPUSER_NAME,'
         +'    EDITOR_CODE=:EDITOR_CODE,'
         +'    EDITOR_NAME=:EDITOR_NAME,'
         +'    GB_CODE=:GB_CODE,'
         +'    GB_NAME=:GB_NAME,'
         +'    FM_CODE=:FM_CODE,'
         +'    FM_NAME=:FM_NAME,'
         +'    PAY_ACCOUNT_NO=:PAY_ACCOUNT_NO,'
         +'    PAY_ACCOUNT_NAME=:PAY_ACCOUNT_NAME,'
         +'    PAY_ACCOUNT_BANK=:PAY_ACCOUNT_BANK,'
         +'    CLEAR_ACCOUNT_NO=:CLEAR_ACCOUNT_NO,'
         +'    CLEAR_ACCOUNT_NAME=:CLEAR_ACCOUNT_NAME,'
         +'    CLEAR_ACCOUNT_BANK=:CLEAR_ACCOUNT_BANK,'
         +'    INCOME_ACCOUNT_NO=:INCOME_ACCOUNT_NO,'
         +'    INCOME_ACCOUNT_NAME=:INCOME_ACCOUNT_NAME,'
         +'    INCOME_ACCOUNT_BANK=:INCOME_ACCOUNT_BANK,'
         +'    PF_ID=:PF_ID,'
         +'    PF_CODE=:PF_CODE,'
         +'    PF_NAME=:PF_NAME,'
         +'    GROUPID_ID=:GROUPID_ID,'
         +'    GROUPID_CODE=:GROUPID_CODE,'
         +'    GROUPID_NAME=:GROUPID_NAME,'
         +'    USEEN_ID=:USEEN_ID,'
         +'    USEEN_CODE=:USEEN_CODE,'
         +'    USEEN_NAME=:USEEN_NAME,'
         +'    PROV_ID=:PROV_ID,'
         +'    PROV_CODE=:PROV_CODE,'
         +'    PROV_NAME=:PROV_NAME,'
         +'    AGENCY_ID=:AGENCY_ID,'
         +'    AGENCY_CODE=:AGENCY_CODE,'
         +'    AGENCY_NAME=:AGENCY_NAME,'
         +'    MODE_ID=:MODE_ID,'
         +'    MODE_CODE=:MODE_CODE,'
         +'    MODE_NAME=:MODE_NAME,'
         +'    FASN_ID=:FASN_ID,'
         +'    FASN_CODE=:FASN_CODE,'
         +'    FASN_NAME=:FASN_NAME,'
         +'    DIR_ID=:DIR_ID,'
         +'    DIR_CODE=:DIR_CODE,'
         +'    DIR_NAME=:DIR_NAME,'
         +'    GPPLAN_ID=:GPPLAN_ID,'
         +'    GPPLAN_CODE=:GPPLAN_CODE,'
         +'    GPPLAN_NAME=:GPPLAN_NAME,'
         +'    GPBARN_ID=:GPBARN_ID,'
         +'    GPBARN_CODE=:GPBARN_CODE,'
         +'    GPBARN_NAME=:GPBARN_NAME,'
         +'    WA_ID=:WA_ID,'
         +'    WA_CODE=:WA_CODE,'
         +'    WA_NAME=:WA_NAME,'
         +'    FF_ID=:FF_ID,'
         +'    FF_NAME=:FF_NAME,'
         +'    FF_CODE=:FF_CODE,'
         +'    IEN_ID=:IEN_ID,'
         +'    IEN_NAME=:IEN_NAME,'
         +'    IEN_CODE=:IEN_CODE,'
         +'    SALTAG_ID=:SALTAG_ID,'
         +'    SALTAG_NAME=:SALTAG_NAME,'
         +'    SALTAG_CODE=:SALTAG_CODE,'
         +'    BC_ID=:BC_ID,'
         +'    BC_CODE=:BC_CODE,'
         +'    BC_NAME=:BC_NAME,'
         +'    BSO_ID=:BSO_ID,'
         +'    BSO_CODE=:BSO_CODE,'
         +'    BSO_NAME=:BSO_NAME,'
         +'    AE_ID=:AE_ID,'
         +'    AE_CODE=:AE_CODE,'
         +'    AE_NAME=:AE_NAME,'
         +'    BUDGET_VOU_ID=:BUDGET_VOU_ID,'
         +'    BUDGET_VOU_CODE=:BUDGET_VOU_CODE,'
         +'    BUDGET_VOU_NAME=:BUDGET_VOU_NAME,'
         +'    MD5=:MD5,'
         +'    GP_VOU_ID=:GP_VOU_ID,'
         +'    GP_VOU_CODE=:GP_VOU_CODE,'
         +'    GP_VOU_NAME=:GP_VOU_NAME'
         +'    WHERE EN_ID=:EN_ID'
         +'    AND   CCID=:CCID';
end;

constructor TGLCCIDS.Create;
begin

end;

destructor TGLCCIDS.Destroy;
begin

  inherited;
end;

class function TGLCCIDS.ReadDS(AUniQuery: TUniQuery): TUniEngine;
var
  I:Integer;
  Field:TField;
  FieldName:string;
begin
  Result:=TGLCCIDS.Create;

  with TGLCCIDS(Result) do
  begin
    for I:=0 to AUniQuery.Fields.Count-1 do
    begin
      Field:=AUniQuery.Fields.Fields[I];
      //if field.fieldname is not all uppercase,please use uppercase().
      FieldName:=Field.FieldName;
      if FieldName='LATEST_OP_DATE' then
      begin
        LATESTOPDATE:=Field.AsString;
      end else
      if FieldName='LATEST_OP_USER' then
      begin
        LATESTOPUSER:=Field.AsString;
      end else
      if FieldName='COA_ID' then
      begin
        COAID    :=Field.AsString;
      end else
      if FieldName='AS_ID' then
      begin
        ASID     :=Field.AsString;
      end else
      if FieldName='EN_ID' then
      begin
        ENID     :=Field.AsString;
      end else
      if FieldName='MK_ID' then
      begin
        MKID     :=Field.AsString;
      end else
      if FieldName='BS_ID' then
      begin
        BSID     :=Field.AsString;
      end else
      if FieldName='BI_ID' then
      begin
        BIID     :=Field.AsString;
      end else
      if FieldName='BSI_ID' then
      begin
        BSIID    :=Field.AsString;
      end else
      if FieldName='PK_ID' then
      begin
        PKID     :=Field.AsString;
      end else
      if FieldName='BO_ID' then
      begin
        BOID     :=Field.AsString;
      end else
      if FieldName='BK_ID' then
      begin
        BKID     :=Field.AsString;
      end else
      if FieldName='MB_ID' then
      begin
        MBID     :=Field.AsString;
      end else
      if FieldName='FILE_ID' then
      begin
        FILEID   :=Field.AsString;
      end else
      if FieldName='PM_ID' then
      begin
        PMID     :=Field.AsString;
      end else
      if FieldName='IN_BS_ID' then
      begin
        INBSID   :=Field.AsString;
      end else
      if FieldName='IN_BIS_ID' then
      begin
        INBISID  :=Field.AsString;
      end else
      if FieldName='CB_ID' then
      begin
        CBID     :=Field.AsString;
      end else
      if FieldName='PB_ID' then
      begin
        PBID     :=Field.AsString;
      end else
      if FieldName='IB_ID' then
      begin
        IBID     :=Field.AsString;
      end else
      if FieldName='BAC_ID' then
      begin
        BACID    :=Field.AsString;
      end else
      if FieldName='BAP_ID' then
      begin
        BAPID    :=Field.AsString;
      end else
      if FieldName='BAI_ID' then
      begin
        BAIID    :=Field.AsString;
      end else
      if FieldName='BT_ID' then
      begin
        BTID     :=Field.AsString;
      end else
      if FieldName='BP_ID' then
      begin
        BPID     :=Field.AsString;
      end else
      if FieldName='BL_ID' then
      begin
        BLID     :=Field.AsString;
      end else
      if FieldName='HOLD1_ID' then
      begin
        HOLD1ID  :=Field.AsString;
      end else
      if FieldName='HOLD2_ID' then
      begin
        HOLD2ID  :=Field.AsString;
      end else
      if FieldName='HOLD3_ID' then
      begin
        HOLD3ID  :=Field.AsString;
      end else
      if FieldName='HOLD4_ID' then
      begin
        HOLD4ID  :=Field.AsString;
      end else
      if FieldName='HOLD5_ID' then
      begin
        HOLD5ID  :=Field.AsString;
      end else
      if FieldName='HOLD6_ID' then
      begin
        HOLD6ID  :=Field.AsString;
      end else
      if FieldName='HOLD7_ID' then
      begin
        HOLD7ID  :=Field.AsString;
      end else
      if FieldName='HOLD8_ID' then
      begin
        HOLD8ID  :=Field.AsString;
      end else
      if FieldName='HOLD9_ID' then
      begin
        HOLD9ID  :=Field.AsString;
      end else
      if FieldName='HOLD10_ID' then
      begin
        HOLD10ID :=Field.AsString;
      end else
      if FieldName='HOLD11_ID' then
      begin
        HOLD11ID :=Field.AsString;
      end else
      if FieldName='HOLD12_ID' then
      begin
        HOLD12ID :=Field.AsString;
      end else
      if FieldName='HOLD13_ID' then
      begin
        HOLD13ID :=Field.AsString;
      end else
      if FieldName='HOLD14_ID' then
      begin
        HOLD14ID :=Field.AsString;
      end else
      if FieldName='HOLD15_ID' then
      begin
        HOLD15ID :=Field.AsString;
      end else
      if FieldName='HOLD16_ID' then
      begin
        HOLD16ID :=Field.AsString;
      end else
      if FieldName='HOLD17_ID' then
      begin
        HOLD17ID :=Field.AsString;
      end else
      if FieldName='HOLD18_ID' then
      begin
        HOLD18ID :=Field.AsString;
      end else
      if FieldName='HOLD19_ID' then
      begin
        HOLD19ID :=Field.AsString;
      end else
      if FieldName='HOLD20_ID' then
      begin
        HOLD20ID :=Field.AsString;
      end else
      if FieldName='HOLD21_ID' then
      begin
        HOLD21ID :=Field.AsString;
      end else
      if FieldName='HOLD22_ID' then
      begin
        HOLD22ID :=Field.AsString;
      end else
      if FieldName='HOLD23_ID' then
      begin
        HOLD23ID :=Field.AsString;
      end else
      if FieldName='HOLD24_ID' then
      begin
        HOLD24ID :=Field.AsString;
      end else
      if FieldName='HOLD25_ID' then
      begin
        HOLD25ID :=Field.AsString;
      end else
      if FieldName='HOLD26_ID' then
      begin
        HOLD26ID :=Field.AsString;
      end else
      if FieldName='HOLD27_ID' then
      begin
        HOLD27ID :=Field.AsString;
      end else
      if FieldName='HOLD28_ID' then
      begin
        HOLD28ID :=Field.AsString;
      end else
      if FieldName='HOLD29_ID' then
      begin
        HOLD29ID :=Field.AsString;
      end else
      if FieldName='HOLD30_ID' then
      begin
        HOLD30ID :=Field.AsString;
      end else
      if FieldName='SET_YEAR' then
      begin
        SETYEAR  :=Field.AsFloat;
      end else
      if FieldName='BIS_ID' then
      begin
        BISID    :=Field.AsString;
      end else
      if FieldName='INPM_ID' then
      begin
        INPMID   :=Field.AsString;
      end else
      if FieldName='ST_ID' then
      begin
        STID     :=Field.AsString;
      end else
      if FieldName='CT_ID' then
      begin
        CTID     :=Field.AsString;
      end else
      if FieldName='SM_ID' then
      begin
        SMID     :=Field.AsString;
      end else
      if FieldName='OPUSER_ID' then
      begin
        OPUSERID :=Field.AsString;
      end else
      if FieldName='EDITOR_ID' then
      begin
        EDITORID :=Field.AsString;
      end else
      if FieldName='GB_ID' then
      begin
        GBID     :=Field.AsString;
      end else
      if FieldName='FM_ID' then
      begin
        FMID     :=Field.AsString;
      end else
      if FieldName='AS_CODE' then
      begin
        ASCODE   :=Field.AsString;
      end else
      if FieldName='AS_NAME' then
      begin
        ASNAME   :=Field.AsString;
      end else
      if FieldName='EN_CODE' then
      begin
        ENCODE   :=Field.AsString;
      end else
      if FieldName='EN_NAME' then
      begin
        ENNAME   :=Field.AsString;
      end else
      if FieldName='MK_CODE' then
      begin
        MKCODE   :=Field.AsString;
      end else
      if FieldName='MK_NAME' then
      begin
        MKNAME   :=Field.AsString;
      end else
      if FieldName='BS_CODE' then
      begin
        BSCODE   :=Field.AsString;
      end else
      if FieldName='BS_NAME' then
      begin
        BSNAME   :=Field.AsString;
      end else
      if FieldName='BI_CODE' then
      begin
        BICODE   :=Field.AsString;
      end else
      if FieldName='BI_NAME' then
      begin
        BINAME   :=Field.AsString;
      end else
      if FieldName='BSI_CODE' then
      begin
        BSICODE  :=Field.AsString;
      end else
      if FieldName='BSI_NAME' then
      begin
        BSINAME  :=Field.AsString;
      end else
      if FieldName='PK_CODE' then
      begin
        PKCODE   :=Field.AsString;
      end else
      if FieldName='PK_NAME' then
      begin
        PKNAME   :=Field.AsString;
      end else
      if FieldName='BO_CODE' then
      begin
        BOCODE   :=Field.AsString;
      end else
      if FieldName='BO_NAME' then
      begin
        BONAME   :=Field.AsString;
      end else
      if FieldName='BK_CODE' then
      begin
        BKCODE   :=Field.AsString;
      end else
      if FieldName='BK_NAME' then
      begin
        BKNAME   :=Field.AsString;
      end else
      if FieldName='MB_CODE' then
      begin
        MBCODE   :=Field.AsString;
      end else
      if FieldName='MB_NAME' then
      begin
        MBNAME   :=Field.AsString;
      end else
      if FieldName='FILE_CODE' then
      begin
        FILECODE :=Field.AsString;
      end else
      if FieldName='FILE_NAME' then
      begin
        FILENAME :=Field.AsString;
      end else
      if FieldName='PM_CODE' then
      begin
        PMCODE   :=Field.AsString;
      end else
      if FieldName='PM_NAME' then
      begin
        PMNAME   :=Field.AsString;
      end else
      if FieldName='IN_BS_CODE' then
      begin
        INBSCODE :=Field.AsString;
      end else
      if FieldName='IN_BS_NAME' then
      begin
        INBSNAME :=Field.AsString;
      end else
      if FieldName='IN_BIS_CODE' then
      begin
        INBISCODE:=Field.AsString;
      end else
      if FieldName='IN_BIS_NAME' then
      begin
        INBISNAME:=Field.AsString;
      end else
      if FieldName='CB_CODE' then
      begin
        CBCODE   :=Field.AsString;
      end else
      if FieldName='CB_NAME' then
      begin
        CBNAME   :=Field.AsString;
      end else
      if FieldName='PB_CODE' then
      begin
        PBCODE   :=Field.AsString;
      end else
      if FieldName='PB_NAME' then
      begin
        PBNAME   :=Field.AsString;
      end else
      if FieldName='IB_CODE' then
      begin
        IBCODE   :=Field.AsString;
      end else
      if FieldName='IB_NAME' then
      begin
        IBNAME   :=Field.AsString;
      end else
      if FieldName='BAC_CODE' then
      begin
        BACCODE  :=Field.AsString;
      end else
      if FieldName='BAC_NAME' then
      begin
        BACNAME  :=Field.AsString;
      end else
      if FieldName='BAP_CODE' then
      begin
        BAPCODE  :=Field.AsString;
      end else
      if FieldName='BAP_NAME' then
      begin
        BAPNAME  :=Field.AsString;
      end else
      if FieldName='BAI_CODE' then
      begin
        BAICODE  :=Field.AsString;
      end else
      if FieldName='BAI_NAME' then
      begin
        BAINAME  :=Field.AsString;
      end else
      if FieldName='BT_CODE' then
      begin
        BTCODE   :=Field.AsString;
      end else
      if FieldName='BT_NAME' then
      begin
        BTNAME   :=Field.AsString;
      end else
      if FieldName='BP_CODE' then
      begin
        BPCODE   :=Field.AsString;
      end else
      if FieldName='BP_NAME' then
      begin
        BPNAME   :=Field.AsString;
      end else
      if FieldName='BL_CODE' then
      begin
        BLCODE   :=Field.AsString;
      end else
      if FieldName='BL_NAME' then
      begin
        BLNAME   :=Field.AsString;
      end else
      if FieldName='HOLD1_CODE' then
      begin
        HOLD1CODE:=Field.AsString;
      end else
      if FieldName='HOLD1_NAME' then
      begin
        HOLD1NAME:=Field.AsString;
      end else
      if FieldName='HOLD2_CODE' then
      begin
        HOLD2CODE:=Field.AsString;
      end else
      if FieldName='HOLD2_NAME' then
      begin
        HOLD2NAME:=Field.AsString;
      end else
      if FieldName='HOLD3_CODE' then
      begin
        HOLD3CODE:=Field.AsString;
      end else
      if FieldName='HOLD3_NAME' then
      begin
        HOLD3NAME:=Field.AsString;
      end else
      if FieldName='HOLD4_CODE' then
      begin
        HOLD4CODE:=Field.AsString;
      end else
      if FieldName='HOLD4_NAME' then
      begin
        HOLD4NAME:=Field.AsString;
      end else
      if FieldName='HOLD5_CODE' then
      begin
        HOLD5CODE:=Field.AsString;
      end else
      if FieldName='HOLD5_NAME' then
      begin
        HOLD5NAME:=Field.AsString;
      end else
      if FieldName='HOLD6_CODE' then
      begin
        HOLD6CODE:=Field.AsString;
      end else
      if FieldName='HOLD6_NAME' then
      begin
        HOLD6NAME:=Field.AsString;
      end else
      if FieldName='HOLD7_CODE' then
      begin
        HOLD7CODE:=Field.AsString;
      end else
      if FieldName='HOLD7_NAME' then
      begin
        HOLD7NAME:=Field.AsString;
      end else
      if FieldName='HOLD8_CODE' then
      begin
        HOLD8CODE:=Field.AsString;
      end else
      if FieldName='HOLD8_NAME' then
      begin
        HOLD8NAME:=Field.AsString;
      end else
      if FieldName='HOLD9_CODE' then
      begin
        HOLD9CODE:=Field.AsString;
      end else
      if FieldName='HOLD9_NAME' then
      begin
        HOLD9NAME:=Field.AsString;
      end else
      if FieldName='HOLD10_CODE' then
      begin
        HOLD10CODE:=Field.AsString;
      end else
      if FieldName='HOLD10_NAME' then
      begin
        HOLD10NAME:=Field.AsString;
      end else
      if FieldName='HOLD11_CODE' then
      begin
        HOLD11CODE:=Field.AsString;
      end else
      if FieldName='HOLD11_NAME' then
      begin
        HOLD11NAME:=Field.AsString;
      end else
      if FieldName='HOLD12_CODE' then
      begin
        HOLD12CODE:=Field.AsString;
      end else
      if FieldName='HOLD12_NAME' then
      begin
        HOLD12NAME:=Field.AsString;
      end else
      if FieldName='HOLD13_CODE' then
      begin
        HOLD13CODE:=Field.AsString;
      end else
      if FieldName='HOLD13_NAME' then
      begin
        HOLD13NAME:=Field.AsString;
      end else
      if FieldName='HOLD14_CODE' then
      begin
        HOLD14CODE:=Field.AsString;
      end else
      if FieldName='HOLD14_NAME' then
      begin
        HOLD14NAME:=Field.AsString;
      end else
      if FieldName='HOLD15_CODE' then
      begin
        HOLD15CODE:=Field.AsString;
      end else
      if FieldName='HOLD15_NAME' then
      begin
        HOLD15NAME:=Field.AsString;
      end else
      if FieldName='HOLD16_CODE' then
      begin
        HOLD16CODE:=Field.AsString;
      end else
      if FieldName='HOLD16_NAME' then
      begin
        HOLD16NAME:=Field.AsString;
      end else
      if FieldName='HOLD17_CODE' then
      begin
        HOLD17CODE:=Field.AsString;
      end else
      if FieldName='HOLD17_NAME' then
      begin
        HOLD17NAME:=Field.AsString;
      end else
      if FieldName='HOLD18_CODE' then
      begin
        HOLD18CODE:=Field.AsString;
      end else
      if FieldName='HOLD18_NAME' then
      begin
        HOLD18NAME:=Field.AsString;
      end else
      if FieldName='HOLD19_CODE' then
      begin
        HOLD19CODE:=Field.AsString;
      end else
      if FieldName='HOLD19_NAME' then
      begin
        HOLD19NAME:=Field.AsString;
      end else
      if FieldName='HOLD20_CODE' then
      begin
        HOLD20CODE:=Field.AsString;
      end else
      if FieldName='HOLD20_NAME' then
      begin
        HOLD20NAME:=Field.AsString;
      end else
      if FieldName='HOLD21_CODE' then
      begin
        HOLD21CODE:=Field.AsString;
      end else
      if FieldName='HOLD21_NAME' then
      begin
        HOLD21NAME:=Field.AsString;
      end else
      if FieldName='HOLD22_CODE' then
      begin
        HOLD22CODE:=Field.AsString;
      end else
      if FieldName='HOLD22_NAME' then
      begin
        HOLD22NAME:=Field.AsString;
      end else
      if FieldName='HOLD23_CODE' then
      begin
        HOLD23CODE:=Field.AsString;
      end else
      if FieldName='HOLD23_NAME' then
      begin
        HOLD23NAME:=Field.AsString;
      end else
      if FieldName='HOLD24_CODE' then
      begin
        HOLD24CODE:=Field.AsString;
      end else
      if FieldName='HOLD24_NAME' then
      begin
        HOLD24NAME:=Field.AsString;
      end else
      if FieldName='HOLD25_CODE' then
      begin
        HOLD25CODE:=Field.AsString;
      end else
      if FieldName='HOLD25_NAME' then
      begin
        HOLD25NAME:=Field.AsString;
      end else
      if FieldName='HOLD26_CODE' then
      begin
        HOLD26CODE:=Field.AsString;
      end else
      if FieldName='HOLD26_NAME' then
      begin
        HOLD26NAME:=Field.AsString;
      end else
      if FieldName='HOLD27_CODE' then
      begin
        HOLD27CODE:=Field.AsString;
      end else
      if FieldName='HOLD27_NAME' then
      begin
        HOLD27NAME:=Field.AsString;
      end else
      if FieldName='HOLD28_CODE' then
      begin
        HOLD28CODE:=Field.AsString;
      end else
      if FieldName='HOLD28_NAME' then
      begin
        HOLD28NAME:=Field.AsString;
      end else
      if FieldName='HOLD29_CODE' then
      begin
        HOLD29CODE:=Field.AsString;
      end else
      if FieldName='HOLD29_NAME' then
      begin
        HOLD29NAME:=Field.AsString;
      end else
      if FieldName='HOLD30_CODE' then
      begin
        HOLD30CODE:=Field.AsString;
      end else
      if FieldName='HOLD30_NAME' then
      begin
        HOLD30NAME:=Field.AsString;
      end else
      if FieldName='BIS_CODE' then
      begin
        BISCODE  :=Field.AsString;
      end else
      if FieldName='BIS_NAME' then
      begin
        BISNAME  :=Field.AsString;
      end else
      if FieldName='INPM_CODE' then
      begin
        INPMCODE :=Field.AsString;
      end else
      if FieldName='INPM_NAME' then
      begin
        INPMNAME :=Field.AsString;
      end else
      if FieldName='ST_CODE' then
      begin
        STCODE   :=Field.AsString;
      end else
      if FieldName='ST_NAME' then
      begin
        STNAME   :=Field.AsString;
      end else
      if FieldName='CT_CODE' then
      begin
        CTCODE   :=Field.AsString;
      end else
      if FieldName='CT_NAME' then
      begin
        CTNAME   :=Field.AsString;
      end else
      if FieldName='SM_CODE' then
      begin
        SMCODE   :=Field.AsString;
      end else
      if FieldName='SM_NAME' then
      begin
        SMNAME   :=Field.AsString;
      end else
      if FieldName='OPUSER_CODE' then
      begin
        OPUSERCODE:=Field.AsString;
      end else
      if FieldName='OPUSER_NAME' then
      begin
        OPUSERNAME:=Field.AsString;
      end else
      if FieldName='EDITOR_CODE' then
      begin
        EDITORCODE:=Field.AsString;
      end else
      if FieldName='EDITOR_NAME' then
      begin
        EDITORNAME:=Field.AsString;
      end else
      if FieldName='GB_CODE' then
      begin
        GBCODE   :=Field.AsString;
      end else
      if FieldName='GB_NAME' then
      begin
        GBNAME   :=Field.AsString;
      end else
      if FieldName='FM_CODE' then
      begin
        FMCODE   :=Field.AsString;
      end else
      if FieldName='FM_NAME' then
      begin
        FMNAME   :=Field.AsString;
      end else
      if FieldName='PAY_ACCOUNT_NO' then
      begin
        PAYACCOUNTNO:=Field.AsString;
      end else
      if FieldName='PAY_ACCOUNT_NAME' then
      begin
        PAYACCOUNTNAME:=Field.AsString;
      end else
      if FieldName='PAY_ACCOUNT_BANK' then
      begin
        PAYACCOUNTBANK:=Field.AsString;
      end else
      if FieldName='CLEAR_ACCOUNT_NO' then
      begin
        CLEARACCOUNTNO:=Field.AsString;
      end else
      if FieldName='CLEAR_ACCOUNT_NAME' then
      begin
        CLEARACCOUNTNAME:=Field.AsString;
      end else
      if FieldName='CLEAR_ACCOUNT_BANK' then
      begin
        CLEARACCOUNTBANK:=Field.AsString;
      end else
      if FieldName='INCOME_ACCOUNT_NO' then
      begin
        INCOMEACCOUNTNO:=Field.AsString;
      end else
      if FieldName='INCOME_ACCOUNT_NAME' then
      begin
        INCOMEACCOUNTNAME:=Field.AsString;
      end else
      if FieldName='INCOME_ACCOUNT_BANK' then
      begin
        INCOMEACCOUNTBANK:=Field.AsString;
      end else
      if FieldName='PF_ID' then
      begin
        PFID     :=Field.AsString;
      end else
      if FieldName='PF_CODE' then
      begin
        PFCODE   :=Field.AsString;
      end else
      if FieldName='PF_NAME' then
      begin
        PFNAME   :=Field.AsString;
      end else
      if FieldName='GROUPID_ID' then
      begin
        GROUPIDID:=Field.AsString;
      end else
      if FieldName='GROUPID_CODE' then
      begin
        GROUPIDCODE:=Field.AsString;
      end else
      if FieldName='GROUPID_NAME' then
      begin
        GROUPIDNAME:=Field.AsString;
      end else
      if FieldName='USEEN_ID' then
      begin
        USEENID  :=Field.AsString;
      end else
      if FieldName='USEEN_CODE' then
      begin
        USEENCODE:=Field.AsString;
      end else
      if FieldName='USEEN_NAME' then
      begin
        USEENNAME:=Field.AsString;
      end else
      if FieldName='PROV_ID' then
      begin
        PROVID   :=Field.AsString;
      end else
      if FieldName='PROV_CODE' then
      begin
        PROVCODE :=Field.AsString;
      end else
      if FieldName='PROV_NAME' then
      begin
        PROVNAME :=Field.AsString;
      end else
      if FieldName='AGENCY_ID' then
      begin
        AGENCYID :=Field.AsString;
      end else
      if FieldName='AGENCY_CODE' then
      begin
        AGENCYCODE:=Field.AsString;
      end else
      if FieldName='AGENCY_NAME' then
      begin
        AGENCYNAME:=Field.AsString;
      end else
      if FieldName='MODE_ID' then
      begin
        MODEID   :=Field.AsString;
      end else
      if FieldName='MODE_CODE' then
      begin
        MODECODE :=Field.AsString;
      end else
      if FieldName='MODE_NAME' then
      begin
        MODENAME :=Field.AsString;
      end else
      if FieldName='FASN_ID' then
      begin
        FASNID   :=Field.AsString;
      end else
      if FieldName='FASN_CODE' then
      begin
        FASNCODE :=Field.AsString;
      end else
      if FieldName='FASN_NAME' then
      begin
        FASNNAME :=Field.AsString;
      end else
      if FieldName='DIR_ID' then
      begin
        DIRID    :=Field.AsString;
      end else
      if FieldName='DIR_CODE' then
      begin
        DIRCODE  :=Field.AsString;
      end else
      if FieldName='DIR_NAME' then
      begin
        DIRNAME  :=Field.AsString;
      end else
      if FieldName='GPPLAN_ID' then
      begin
        GPPLANID :=Field.AsString;
      end else
      if FieldName='GPPLAN_CODE' then
      begin
        GPPLANCODE:=Field.AsString;
      end else
      if FieldName='GPPLAN_NAME' then
      begin
        GPPLANNAME:=Field.AsString;
      end else
      if FieldName='GPBARN_ID' then
      begin
        GPBARNID :=Field.AsString;
      end else
      if FieldName='GPBARN_CODE' then
      begin
        GPBARNCODE:=Field.AsString;
      end else
      if FieldName='GPBARN_NAME' then
      begin
        GPBARNNAME:=Field.AsString;
      end else
      if FieldName='WA_ID' then
      begin
        WAID     :=Field.AsString;
      end else
      if FieldName='WA_CODE' then
      begin
        WACODE   :=Field.AsString;
      end else
      if FieldName='WA_NAME' then
      begin
        WANAME   :=Field.AsString;
      end else
      if FieldName='FF_ID' then
      begin
        FFID     :=Field.AsString;
      end else
      if FieldName='FF_NAME' then
      begin
        FFNAME   :=Field.AsString;
      end else
      if FieldName='FF_CODE' then
      begin
        FFCODE   :=Field.AsString;
      end else
      if FieldName='IEN_ID' then
      begin
        IENID    :=Field.AsString;
      end else
      if FieldName='IEN_NAME' then
      begin
        IENNAME  :=Field.AsString;
      end else
      if FieldName='IEN_CODE' then
      begin
        IENCODE  :=Field.AsString;
      end else
      if FieldName='SALTAG_ID' then
      begin
        SALTAGID :=Field.AsString;
      end else
      if FieldName='SALTAG_NAME' then
      begin
        SALTAGNAME:=Field.AsString;
      end else
      if FieldName='SALTAG_CODE' then
      begin
        SALTAGCODE:=Field.AsString;
      end else
      if FieldName='BC_ID' then
      begin
        BCID     :=Field.AsString;
      end else
      if FieldName='BC_CODE' then
      begin
        BCCODE   :=Field.AsString;
      end else
      if FieldName='BC_NAME' then
      begin
        BCNAME   :=Field.AsString;
      end else
      if FieldName='BSO_ID' then
      begin
        BSOID    :=Field.AsString;
      end else
      if FieldName='BSO_CODE' then
      begin
        BSOCODE  :=Field.AsString;
      end else
      if FieldName='BSO_NAME' then
      begin
        BSONAME  :=Field.AsString;
      end else
      if FieldName='AE_ID' then
      begin
        AEID     :=Field.AsString;
      end else
      if FieldName='AE_CODE' then
      begin
        AECODE   :=Field.AsString;
      end else
      if FieldName='AE_NAME' then
      begin
        AENAME   :=Field.AsString;
      end else
      if FieldName='CCID' then
      begin
        CCID     :=Field.AsFloat;
      end else
      if FieldName='BUDGET_VOU_ID' then
      begin
        BUDGETVOUID:=Field.AsString;
      end else
      if FieldName='BUDGET_VOU_CODE' then
      begin
        BUDGETVOUCODE:=Field.AsString;
      end else
      if FieldName='BUDGET_VOU_NAME' then
      begin
        BUDGETVOUNAME:=Field.AsString;
      end else
      if FieldName='MD5' then
      begin
        MD5      :=Field.AsString;
      end else
      if FieldName='GP_VOU_ID' then
      begin
        GPVOUID  :=Field.AsString;
      end else
      if FieldName='GP_VOU_CODE' then
      begin
        GPVOUCODE:=Field.AsString;
      end else
      if FieldName='GP_VOU_NAME' then
      begin
        GPVOUNAME:=Field.AsString;
      end;
    end
  end;  
end;

class procedure TGLCCIDS.ReadDS(AUniQuery: TUniQuery; var Result: TUniEngine);
var
  I:Integer;
  Field:TField;
  FieldName:string;
begin
  if Result=nil then Exit;

  with TGLCCIDS(Result) do
  begin
    for I:=0 to AUniQuery.Fields.Count-1 do
    begin
      Field:=AUniQuery.Fields.Fields[I];
      //if field.fieldname is not all uppercase,please use uppercase().
      FieldName:=Field.FieldName;
      if FieldName='LATEST_OP_DATE' then
      begin
        LATESTOPDATE:=Field.AsString;
      end else
      if FieldName='LATEST_OP_USER' then
      begin
        LATESTOPUSER:=Field.AsString;
      end else
      if FieldName='COA_ID' then
      begin
        COAID    :=Field.AsString;
      end else
      if FieldName='AS_ID' then
      begin
        ASID     :=Field.AsString;
      end else
      if FieldName='EN_ID' then
      begin
        ENID     :=Field.AsString;
      end else
      if FieldName='MK_ID' then
      begin
        MKID     :=Field.AsString;
      end else
      if FieldName='BS_ID' then
      begin
        BSID     :=Field.AsString;
      end else
      if FieldName='BI_ID' then
      begin
        BIID     :=Field.AsString;
      end else
      if FieldName='BSI_ID' then
      begin
        BSIID    :=Field.AsString;
      end else
      if FieldName='PK_ID' then
      begin
        PKID     :=Field.AsString;
      end else
      if FieldName='BO_ID' then
      begin
        BOID     :=Field.AsString;
      end else
      if FieldName='BK_ID' then
      begin
        BKID     :=Field.AsString;
      end else
      if FieldName='MB_ID' then
      begin
        MBID     :=Field.AsString;
      end else
      if FieldName='FILE_ID' then
      begin
        FILEID   :=Field.AsString;
      end else
      if FieldName='PM_ID' then
      begin
        PMID     :=Field.AsString;
      end else
      if FieldName='IN_BS_ID' then
      begin
        INBSID   :=Field.AsString;
      end else
      if FieldName='IN_BIS_ID' then
      begin
        INBISID  :=Field.AsString;
      end else
      if FieldName='CB_ID' then
      begin
        CBID     :=Field.AsString;
      end else
      if FieldName='PB_ID' then
      begin
        PBID     :=Field.AsString;
      end else
      if FieldName='IB_ID' then
      begin
        IBID     :=Field.AsString;
      end else
      if FieldName='BAC_ID' then
      begin
        BACID    :=Field.AsString;
      end else
      if FieldName='BAP_ID' then
      begin
        BAPID    :=Field.AsString;
      end else
      if FieldName='BAI_ID' then
      begin
        BAIID    :=Field.AsString;
      end else
      if FieldName='BT_ID' then
      begin
        BTID     :=Field.AsString;
      end else
      if FieldName='BP_ID' then
      begin
        BPID     :=Field.AsString;
      end else
      if FieldName='BL_ID' then
      begin
        BLID     :=Field.AsString;
      end else
      if FieldName='HOLD1_ID' then
      begin
        HOLD1ID  :=Field.AsString;
      end else
      if FieldName='HOLD2_ID' then
      begin
        HOLD2ID  :=Field.AsString;
      end else
      if FieldName='HOLD3_ID' then
      begin
        HOLD3ID  :=Field.AsString;
      end else
      if FieldName='HOLD4_ID' then
      begin
        HOLD4ID  :=Field.AsString;
      end else
      if FieldName='HOLD5_ID' then
      begin
        HOLD5ID  :=Field.AsString;
      end else
      if FieldName='HOLD6_ID' then
      begin
        HOLD6ID  :=Field.AsString;
      end else
      if FieldName='HOLD7_ID' then
      begin
        HOLD7ID  :=Field.AsString;
      end else
      if FieldName='HOLD8_ID' then
      begin
        HOLD8ID  :=Field.AsString;
      end else
      if FieldName='HOLD9_ID' then
      begin
        HOLD9ID  :=Field.AsString;
      end else
      if FieldName='HOLD10_ID' then
      begin
        HOLD10ID :=Field.AsString;
      end else
      if FieldName='HOLD11_ID' then
      begin
        HOLD11ID :=Field.AsString;
      end else
      if FieldName='HOLD12_ID' then
      begin
        HOLD12ID :=Field.AsString;
      end else
      if FieldName='HOLD13_ID' then
      begin
        HOLD13ID :=Field.AsString;
      end else
      if FieldName='HOLD14_ID' then
      begin
        HOLD14ID :=Field.AsString;
      end else
      if FieldName='HOLD15_ID' then
      begin
        HOLD15ID :=Field.AsString;
      end else
      if FieldName='HOLD16_ID' then
      begin
        HOLD16ID :=Field.AsString;
      end else
      if FieldName='HOLD17_ID' then
      begin
        HOLD17ID :=Field.AsString;
      end else
      if FieldName='HOLD18_ID' then
      begin
        HOLD18ID :=Field.AsString;
      end else
      if FieldName='HOLD19_ID' then
      begin
        HOLD19ID :=Field.AsString;
      end else
      if FieldName='HOLD20_ID' then
      begin
        HOLD20ID :=Field.AsString;
      end else
      if FieldName='HOLD21_ID' then
      begin
        HOLD21ID :=Field.AsString;
      end else
      if FieldName='HOLD22_ID' then
      begin
        HOLD22ID :=Field.AsString;
      end else
      if FieldName='HOLD23_ID' then
      begin
        HOLD23ID :=Field.AsString;
      end else
      if FieldName='HOLD24_ID' then
      begin
        HOLD24ID :=Field.AsString;
      end else
      if FieldName='HOLD25_ID' then
      begin
        HOLD25ID :=Field.AsString;
      end else
      if FieldName='HOLD26_ID' then
      begin
        HOLD26ID :=Field.AsString;
      end else
      if FieldName='HOLD27_ID' then
      begin
        HOLD27ID :=Field.AsString;
      end else
      if FieldName='HOLD28_ID' then
      begin
        HOLD28ID :=Field.AsString;
      end else
      if FieldName='HOLD29_ID' then
      begin
        HOLD29ID :=Field.AsString;
      end else
      if FieldName='HOLD30_ID' then
      begin
        HOLD30ID :=Field.AsString;
      end else
      if FieldName='SET_YEAR' then
      begin
        SETYEAR  :=Field.AsFloat;
      end else
      if FieldName='BIS_ID' then
      begin
        BISID    :=Field.AsString;
      end else
      if FieldName='INPM_ID' then
      begin
        INPMID   :=Field.AsString;
      end else
      if FieldName='ST_ID' then
      begin
        STID     :=Field.AsString;
      end else
      if FieldName='CT_ID' then
      begin
        CTID     :=Field.AsString;
      end else
      if FieldName='SM_ID' then
      begin
        SMID     :=Field.AsString;
      end else
      if FieldName='OPUSER_ID' then
      begin
        OPUSERID :=Field.AsString;
      end else
      if FieldName='EDITOR_ID' then
      begin
        EDITORID :=Field.AsString;
      end else
      if FieldName='GB_ID' then
      begin
        GBID     :=Field.AsString;
      end else
      if FieldName='FM_ID' then
      begin
        FMID     :=Field.AsString;
      end else
      if FieldName='AS_CODE' then
      begin
        ASCODE   :=Field.AsString;
      end else
      if FieldName='AS_NAME' then
      begin
        ASNAME   :=Field.AsString;
      end else
      if FieldName='EN_CODE' then
      begin
        ENCODE   :=Field.AsString;
      end else
      if FieldName='EN_NAME' then
      begin
        ENNAME   :=Field.AsString;
      end else
      if FieldName='MK_CODE' then
      begin
        MKCODE   :=Field.AsString;
      end else
      if FieldName='MK_NAME' then
      begin
        MKNAME   :=Field.AsString;
      end else
      if FieldName='BS_CODE' then
      begin
        BSCODE   :=Field.AsString;
      end else
      if FieldName='BS_NAME' then
      begin
        BSNAME   :=Field.AsString;
      end else
      if FieldName='BI_CODE' then
      begin
        BICODE   :=Field.AsString;
      end else
      if FieldName='BI_NAME' then
      begin
        BINAME   :=Field.AsString;
      end else
      if FieldName='BSI_CODE' then
      begin
        BSICODE  :=Field.AsString;
      end else
      if FieldName='BSI_NAME' then
      begin
        BSINAME  :=Field.AsString;
      end else
      if FieldName='PK_CODE' then
      begin
        PKCODE   :=Field.AsString;
      end else
      if FieldName='PK_NAME' then
      begin
        PKNAME   :=Field.AsString;
      end else
      if FieldName='BO_CODE' then
      begin
        BOCODE   :=Field.AsString;
      end else
      if FieldName='BO_NAME' then
      begin
        BONAME   :=Field.AsString;
      end else
      if FieldName='BK_CODE' then
      begin
        BKCODE   :=Field.AsString;
      end else
      if FieldName='BK_NAME' then
      begin
        BKNAME   :=Field.AsString;
      end else
      if FieldName='MB_CODE' then
      begin
        MBCODE   :=Field.AsString;
      end else
      if FieldName='MB_NAME' then
      begin
        MBNAME   :=Field.AsString;
      end else
      if FieldName='FILE_CODE' then
      begin
        FILECODE :=Field.AsString;
      end else
      if FieldName='FILE_NAME' then
      begin
        FILENAME :=Field.AsString;
      end else
      if FieldName='PM_CODE' then
      begin
        PMCODE   :=Field.AsString;
      end else
      if FieldName='PM_NAME' then
      begin
        PMNAME   :=Field.AsString;
      end else
      if FieldName='IN_BS_CODE' then
      begin
        INBSCODE :=Field.AsString;
      end else
      if FieldName='IN_BS_NAME' then
      begin
        INBSNAME :=Field.AsString;
      end else
      if FieldName='IN_BIS_CODE' then
      begin
        INBISCODE:=Field.AsString;
      end else
      if FieldName='IN_BIS_NAME' then
      begin
        INBISNAME:=Field.AsString;
      end else
      if FieldName='CB_CODE' then
      begin
        CBCODE   :=Field.AsString;
      end else
      if FieldName='CB_NAME' then
      begin
        CBNAME   :=Field.AsString;
      end else
      if FieldName='PB_CODE' then
      begin
        PBCODE   :=Field.AsString;
      end else
      if FieldName='PB_NAME' then
      begin
        PBNAME   :=Field.AsString;
      end else
      if FieldName='IB_CODE' then
      begin
        IBCODE   :=Field.AsString;
      end else
      if FieldName='IB_NAME' then
      begin
        IBNAME   :=Field.AsString;
      end else
      if FieldName='BAC_CODE' then
      begin
        BACCODE  :=Field.AsString;
      end else
      if FieldName='BAC_NAME' then
      begin
        BACNAME  :=Field.AsString;
      end else
      if FieldName='BAP_CODE' then
      begin
        BAPCODE  :=Field.AsString;
      end else
      if FieldName='BAP_NAME' then
      begin
        BAPNAME  :=Field.AsString;
      end else
      if FieldName='BAI_CODE' then
      begin
        BAICODE  :=Field.AsString;
      end else
      if FieldName='BAI_NAME' then
      begin
        BAINAME  :=Field.AsString;
      end else
      if FieldName='BT_CODE' then
      begin
        BTCODE   :=Field.AsString;
      end else
      if FieldName='BT_NAME' then
      begin
        BTNAME   :=Field.AsString;
      end else
      if FieldName='BP_CODE' then
      begin
        BPCODE   :=Field.AsString;
      end else
      if FieldName='BP_NAME' then
      begin
        BPNAME   :=Field.AsString;
      end else
      if FieldName='BL_CODE' then
      begin
        BLCODE   :=Field.AsString;
      end else
      if FieldName='BL_NAME' then
      begin
        BLNAME   :=Field.AsString;
      end else
      if FieldName='HOLD1_CODE' then
      begin
        HOLD1CODE:=Field.AsString;
      end else
      if FieldName='HOLD1_NAME' then
      begin
        HOLD1NAME:=Field.AsString;
      end else
      if FieldName='HOLD2_CODE' then
      begin
        HOLD2CODE:=Field.AsString;
      end else
      if FieldName='HOLD2_NAME' then
      begin
        HOLD2NAME:=Field.AsString;
      end else
      if FieldName='HOLD3_CODE' then
      begin
        HOLD3CODE:=Field.AsString;
      end else
      if FieldName='HOLD3_NAME' then
      begin
        HOLD3NAME:=Field.AsString;
      end else
      if FieldName='HOLD4_CODE' then
      begin
        HOLD4CODE:=Field.AsString;
      end else
      if FieldName='HOLD4_NAME' then
      begin
        HOLD4NAME:=Field.AsString;
      end else
      if FieldName='HOLD5_CODE' then
      begin
        HOLD5CODE:=Field.AsString;
      end else
      if FieldName='HOLD5_NAME' then
      begin
        HOLD5NAME:=Field.AsString;
      end else
      if FieldName='HOLD6_CODE' then
      begin
        HOLD6CODE:=Field.AsString;
      end else
      if FieldName='HOLD6_NAME' then
      begin
        HOLD6NAME:=Field.AsString;
      end else
      if FieldName='HOLD7_CODE' then
      begin
        HOLD7CODE:=Field.AsString;
      end else
      if FieldName='HOLD7_NAME' then
      begin
        HOLD7NAME:=Field.AsString;
      end else
      if FieldName='HOLD8_CODE' then
      begin
        HOLD8CODE:=Field.AsString;
      end else
      if FieldName='HOLD8_NAME' then
      begin
        HOLD8NAME:=Field.AsString;
      end else
      if FieldName='HOLD9_CODE' then
      begin
        HOLD9CODE:=Field.AsString;
      end else
      if FieldName='HOLD9_NAME' then
      begin
        HOLD9NAME:=Field.AsString;
      end else
      if FieldName='HOLD10_CODE' then
      begin
        HOLD10CODE:=Field.AsString;
      end else
      if FieldName='HOLD10_NAME' then
      begin
        HOLD10NAME:=Field.AsString;
      end else
      if FieldName='HOLD11_CODE' then
      begin
        HOLD11CODE:=Field.AsString;
      end else
      if FieldName='HOLD11_NAME' then
      begin
        HOLD11NAME:=Field.AsString;
      end else
      if FieldName='HOLD12_CODE' then
      begin
        HOLD12CODE:=Field.AsString;
      end else
      if FieldName='HOLD12_NAME' then
      begin
        HOLD12NAME:=Field.AsString;
      end else
      if FieldName='HOLD13_CODE' then
      begin
        HOLD13CODE:=Field.AsString;
      end else
      if FieldName='HOLD13_NAME' then
      begin
        HOLD13NAME:=Field.AsString;
      end else
      if FieldName='HOLD14_CODE' then
      begin
        HOLD14CODE:=Field.AsString;
      end else
      if FieldName='HOLD14_NAME' then
      begin
        HOLD14NAME:=Field.AsString;
      end else
      if FieldName='HOLD15_CODE' then
      begin
        HOLD15CODE:=Field.AsString;
      end else
      if FieldName='HOLD15_NAME' then
      begin
        HOLD15NAME:=Field.AsString;
      end else
      if FieldName='HOLD16_CODE' then
      begin
        HOLD16CODE:=Field.AsString;
      end else
      if FieldName='HOLD16_NAME' then
      begin
        HOLD16NAME:=Field.AsString;
      end else
      if FieldName='HOLD17_CODE' then
      begin
        HOLD17CODE:=Field.AsString;
      end else
      if FieldName='HOLD17_NAME' then
      begin
        HOLD17NAME:=Field.AsString;
      end else
      if FieldName='HOLD18_CODE' then
      begin
        HOLD18CODE:=Field.AsString;
      end else
      if FieldName='HOLD18_NAME' then
      begin
        HOLD18NAME:=Field.AsString;
      end else
      if FieldName='HOLD19_CODE' then
      begin
        HOLD19CODE:=Field.AsString;
      end else
      if FieldName='HOLD19_NAME' then
      begin
        HOLD19NAME:=Field.AsString;
      end else
      if FieldName='HOLD20_CODE' then
      begin
        HOLD20CODE:=Field.AsString;
      end else
      if FieldName='HOLD20_NAME' then
      begin
        HOLD20NAME:=Field.AsString;
      end else
      if FieldName='HOLD21_CODE' then
      begin
        HOLD21CODE:=Field.AsString;
      end else
      if FieldName='HOLD21_NAME' then
      begin
        HOLD21NAME:=Field.AsString;
      end else
      if FieldName='HOLD22_CODE' then
      begin
        HOLD22CODE:=Field.AsString;
      end else
      if FieldName='HOLD22_NAME' then
      begin
        HOLD22NAME:=Field.AsString;
      end else
      if FieldName='HOLD23_CODE' then
      begin
        HOLD23CODE:=Field.AsString;
      end else
      if FieldName='HOLD23_NAME' then
      begin
        HOLD23NAME:=Field.AsString;
      end else
      if FieldName='HOLD24_CODE' then
      begin
        HOLD24CODE:=Field.AsString;
      end else
      if FieldName='HOLD24_NAME' then
      begin
        HOLD24NAME:=Field.AsString;
      end else
      if FieldName='HOLD25_CODE' then
      begin
        HOLD25CODE:=Field.AsString;
      end else
      if FieldName='HOLD25_NAME' then
      begin
        HOLD25NAME:=Field.AsString;
      end else
      if FieldName='HOLD26_CODE' then
      begin
        HOLD26CODE:=Field.AsString;
      end else
      if FieldName='HOLD26_NAME' then
      begin
        HOLD26NAME:=Field.AsString;
      end else
      if FieldName='HOLD27_CODE' then
      begin
        HOLD27CODE:=Field.AsString;
      end else
      if FieldName='HOLD27_NAME' then
      begin
        HOLD27NAME:=Field.AsString;
      end else
      if FieldName='HOLD28_CODE' then
      begin
        HOLD28CODE:=Field.AsString;
      end else
      if FieldName='HOLD28_NAME' then
      begin
        HOLD28NAME:=Field.AsString;
      end else
      if FieldName='HOLD29_CODE' then
      begin
        HOLD29CODE:=Field.AsString;
      end else
      if FieldName='HOLD29_NAME' then
      begin
        HOLD29NAME:=Field.AsString;
      end else
      if FieldName='HOLD30_CODE' then
      begin
        HOLD30CODE:=Field.AsString;
      end else
      if FieldName='HOLD30_NAME' then
      begin
        HOLD30NAME:=Field.AsString;
      end else
      if FieldName='BIS_CODE' then
      begin
        BISCODE  :=Field.AsString;
      end else
      if FieldName='BIS_NAME' then
      begin
        BISNAME  :=Field.AsString;
      end else
      if FieldName='INPM_CODE' then
      begin
        INPMCODE :=Field.AsString;
      end else
      if FieldName='INPM_NAME' then
      begin
        INPMNAME :=Field.AsString;
      end else
      if FieldName='ST_CODE' then
      begin
        STCODE   :=Field.AsString;
      end else
      if FieldName='ST_NAME' then
      begin
        STNAME   :=Field.AsString;
      end else
      if FieldName='CT_CODE' then
      begin
        CTCODE   :=Field.AsString;
      end else
      if FieldName='CT_NAME' then
      begin
        CTNAME   :=Field.AsString;
      end else
      if FieldName='SM_CODE' then
      begin
        SMCODE   :=Field.AsString;
      end else
      if FieldName='SM_NAME' then
      begin
        SMNAME   :=Field.AsString;
      end else
      if FieldName='OPUSER_CODE' then
      begin
        OPUSERCODE:=Field.AsString;
      end else
      if FieldName='OPUSER_NAME' then
      begin
        OPUSERNAME:=Field.AsString;
      end else
      if FieldName='EDITOR_CODE' then
      begin
        EDITORCODE:=Field.AsString;
      end else
      if FieldName='EDITOR_NAME' then
      begin
        EDITORNAME:=Field.AsString;
      end else
      if FieldName='GB_CODE' then
      begin
        GBCODE   :=Field.AsString;
      end else
      if FieldName='GB_NAME' then
      begin
        GBNAME   :=Field.AsString;
      end else
      if FieldName='FM_CODE' then
      begin
        FMCODE   :=Field.AsString;
      end else
      if FieldName='FM_NAME' then
      begin
        FMNAME   :=Field.AsString;
      end else
      if FieldName='PAY_ACCOUNT_NO' then
      begin
        PAYACCOUNTNO:=Field.AsString;
      end else
      if FieldName='PAY_ACCOUNT_NAME' then
      begin
        PAYACCOUNTNAME:=Field.AsString;
      end else
      if FieldName='PAY_ACCOUNT_BANK' then
      begin
        PAYACCOUNTBANK:=Field.AsString;
      end else
      if FieldName='CLEAR_ACCOUNT_NO' then
      begin
        CLEARACCOUNTNO:=Field.AsString;
      end else
      if FieldName='CLEAR_ACCOUNT_NAME' then
      begin
        CLEARACCOUNTNAME:=Field.AsString;
      end else
      if FieldName='CLEAR_ACCOUNT_BANK' then
      begin
        CLEARACCOUNTBANK:=Field.AsString;
      end else
      if FieldName='INCOME_ACCOUNT_NO' then
      begin
        INCOMEACCOUNTNO:=Field.AsString;
      end else
      if FieldName='INCOME_ACCOUNT_NAME' then
      begin
        INCOMEACCOUNTNAME:=Field.AsString;
      end else
      if FieldName='INCOME_ACCOUNT_BANK' then
      begin
        INCOMEACCOUNTBANK:=Field.AsString;
      end else
      if FieldName='PF_ID' then
      begin
        PFID     :=Field.AsString;
      end else
      if FieldName='PF_CODE' then
      begin
        PFCODE   :=Field.AsString;
      end else
      if FieldName='PF_NAME' then
      begin
        PFNAME   :=Field.AsString;
      end else
      if FieldName='GROUPID_ID' then
      begin
        GROUPIDID:=Field.AsString;
      end else
      if FieldName='GROUPID_CODE' then
      begin
        GROUPIDCODE:=Field.AsString;
      end else
      if FieldName='GROUPID_NAME' then
      begin
        GROUPIDNAME:=Field.AsString;
      end else
      if FieldName='USEEN_ID' then
      begin
        USEENID  :=Field.AsString;
      end else
      if FieldName='USEEN_CODE' then
      begin
        USEENCODE:=Field.AsString;
      end else
      if FieldName='USEEN_NAME' then
      begin
        USEENNAME:=Field.AsString;
      end else
      if FieldName='PROV_ID' then
      begin
        PROVID   :=Field.AsString;
      end else
      if FieldName='PROV_CODE' then
      begin
        PROVCODE :=Field.AsString;
      end else
      if FieldName='PROV_NAME' then
      begin
        PROVNAME :=Field.AsString;
      end else
      if FieldName='AGENCY_ID' then
      begin
        AGENCYID :=Field.AsString;
      end else
      if FieldName='AGENCY_CODE' then
      begin
        AGENCYCODE:=Field.AsString;
      end else
      if FieldName='AGENCY_NAME' then
      begin
        AGENCYNAME:=Field.AsString;
      end else
      if FieldName='MODE_ID' then
      begin
        MODEID   :=Field.AsString;
      end else
      if FieldName='MODE_CODE' then
      begin
        MODECODE :=Field.AsString;
      end else
      if FieldName='MODE_NAME' then
      begin
        MODENAME :=Field.AsString;
      end else
      if FieldName='FASN_ID' then
      begin
        FASNID   :=Field.AsString;
      end else
      if FieldName='FASN_CODE' then
      begin
        FASNCODE :=Field.AsString;
      end else
      if FieldName='FASN_NAME' then
      begin
        FASNNAME :=Field.AsString;
      end else
      if FieldName='DIR_ID' then
      begin
        DIRID    :=Field.AsString;
      end else
      if FieldName='DIR_CODE' then
      begin
        DIRCODE  :=Field.AsString;
      end else
      if FieldName='DIR_NAME' then
      begin
        DIRNAME  :=Field.AsString;
      end else
      if FieldName='GPPLAN_ID' then
      begin
        GPPLANID :=Field.AsString;
      end else
      if FieldName='GPPLAN_CODE' then
      begin
        GPPLANCODE:=Field.AsString;
      end else
      if FieldName='GPPLAN_NAME' then
      begin
        GPPLANNAME:=Field.AsString;
      end else
      if FieldName='GPBARN_ID' then
      begin
        GPBARNID :=Field.AsString;
      end else
      if FieldName='GPBARN_CODE' then
      begin
        GPBARNCODE:=Field.AsString;
      end else
      if FieldName='GPBARN_NAME' then
      begin
        GPBARNNAME:=Field.AsString;
      end else
      if FieldName='WA_ID' then
      begin
        WAID     :=Field.AsString;
      end else
      if FieldName='WA_CODE' then
      begin
        WACODE   :=Field.AsString;
      end else
      if FieldName='WA_NAME' then
      begin
        WANAME   :=Field.AsString;
      end else
      if FieldName='FF_ID' then
      begin
        FFID     :=Field.AsString;
      end else
      if FieldName='FF_NAME' then
      begin
        FFNAME   :=Field.AsString;
      end else
      if FieldName='FF_CODE' then
      begin
        FFCODE   :=Field.AsString;
      end else
      if FieldName='IEN_ID' then
      begin
        IENID    :=Field.AsString;
      end else
      if FieldName='IEN_NAME' then
      begin
        IENNAME  :=Field.AsString;
      end else
      if FieldName='IEN_CODE' then
      begin
        IENCODE  :=Field.AsString;
      end else
      if FieldName='SALTAG_ID' then
      begin
        SALTAGID :=Field.AsString;
      end else
      if FieldName='SALTAG_NAME' then
      begin
        SALTAGNAME:=Field.AsString;
      end else
      if FieldName='SALTAG_CODE' then
      begin
        SALTAGCODE:=Field.AsString;
      end else
      if FieldName='BC_ID' then
      begin
        BCID     :=Field.AsString;
      end else
      if FieldName='BC_CODE' then
      begin
        BCCODE   :=Field.AsString;
      end else
      if FieldName='BC_NAME' then
      begin
        BCNAME   :=Field.AsString;
      end else
      if FieldName='BSO_ID' then
      begin
        BSOID    :=Field.AsString;
      end else
      if FieldName='BSO_CODE' then
      begin
        BSOCODE  :=Field.AsString;
      end else
      if FieldName='BSO_NAME' then
      begin
        BSONAME  :=Field.AsString;
      end else
      if FieldName='AE_ID' then
      begin
        AEID     :=Field.AsString;
      end else
      if FieldName='AE_CODE' then
      begin
        AECODE   :=Field.AsString;
      end else
      if FieldName='AE_NAME' then
      begin
        AENAME   :=Field.AsString;
      end else
      if FieldName='CCID' then
      begin
        CCID     :=Field.AsFloat;
      end else
      if FieldName='BUDGET_VOU_ID' then
      begin
        BUDGETVOUID:=Field.AsString;
      end else
      if FieldName='BUDGET_VOU_CODE' then
      begin
        BUDGETVOUCODE:=Field.AsString;
      end else
      if FieldName='BUDGET_VOU_NAME' then
      begin
        BUDGETVOUNAME:=Field.AsString;
      end else
      if FieldName='MD5' then
      begin
        MD5      :=Field.AsString;
      end else
      if FieldName='GP_VOU_ID' then
      begin
        GPVOUID  :=Field.AsString;
      end else
      if FieldName='GP_VOU_CODE' then
      begin
        GPVOUCODE:=Field.AsString;
      end else
      if FieldName='GP_VOU_NAME' then
      begin
        GPVOUNAME:=Field.AsString;
      end;
    end
  end;  
end;

class function  TGLCCIDS.CopyIt(AGLCCIDS: TGLCCIDS): TGLCCIDS;
begin
  Result:=TGLCCIDS.Create;
  TGLCCIDS.CopyIt(AGLCCIDS,Result)
end;

class procedure TGLCCIDS.CopyIt(AGLCCIDS:TGLCCIDS;var Result:TGLCCIDS);
begin
  if Result=nil then Exit;
  Result.LATESTOPDATE:=AGLCCIDS.LATESTOPDATE;
  Result.LATESTOPUSER:=AGLCCIDS.LATESTOPUSER;
  Result.COAID    :=AGLCCIDS.COAID;
  Result.ASID     :=AGLCCIDS.ASID;
  Result.ENID     :=AGLCCIDS.ENID;
  Result.MKID     :=AGLCCIDS.MKID;
  Result.BSID     :=AGLCCIDS.BSID;
  Result.BIID     :=AGLCCIDS.BIID;
  Result.BSIID    :=AGLCCIDS.BSIID;
  Result.PKID     :=AGLCCIDS.PKID;
  Result.BOID     :=AGLCCIDS.BOID;
  Result.BKID     :=AGLCCIDS.BKID;
  Result.MBID     :=AGLCCIDS.MBID;
  Result.FILEID   :=AGLCCIDS.FILEID;
  Result.PMID     :=AGLCCIDS.PMID;
  Result.INBSID   :=AGLCCIDS.INBSID;
  Result.INBISID  :=AGLCCIDS.INBISID;
  Result.CBID     :=AGLCCIDS.CBID;
  Result.PBID     :=AGLCCIDS.PBID;
  Result.IBID     :=AGLCCIDS.IBID;
  Result.BACID    :=AGLCCIDS.BACID;
  Result.BAPID    :=AGLCCIDS.BAPID;
  Result.BAIID    :=AGLCCIDS.BAIID;
  Result.BTID     :=AGLCCIDS.BTID;
  Result.BPID     :=AGLCCIDS.BPID;
  Result.BLID     :=AGLCCIDS.BLID;
  Result.HOLD1ID  :=AGLCCIDS.HOLD1ID;
  Result.HOLD2ID  :=AGLCCIDS.HOLD2ID;
  Result.HOLD3ID  :=AGLCCIDS.HOLD3ID;
  Result.HOLD4ID  :=AGLCCIDS.HOLD4ID;
  Result.HOLD5ID  :=AGLCCIDS.HOLD5ID;
  Result.HOLD6ID  :=AGLCCIDS.HOLD6ID;
  Result.HOLD7ID  :=AGLCCIDS.HOLD7ID;
  Result.HOLD8ID  :=AGLCCIDS.HOLD8ID;
  Result.HOLD9ID  :=AGLCCIDS.HOLD9ID;
  Result.HOLD10ID :=AGLCCIDS.HOLD10ID;
  Result.HOLD11ID :=AGLCCIDS.HOLD11ID;
  Result.HOLD12ID :=AGLCCIDS.HOLD12ID;
  Result.HOLD13ID :=AGLCCIDS.HOLD13ID;
  Result.HOLD14ID :=AGLCCIDS.HOLD14ID;
  Result.HOLD15ID :=AGLCCIDS.HOLD15ID;
  Result.HOLD16ID :=AGLCCIDS.HOLD16ID;
  Result.HOLD17ID :=AGLCCIDS.HOLD17ID;
  Result.HOLD18ID :=AGLCCIDS.HOLD18ID;
  Result.HOLD19ID :=AGLCCIDS.HOLD19ID;
  Result.HOLD20ID :=AGLCCIDS.HOLD20ID;
  Result.HOLD21ID :=AGLCCIDS.HOLD21ID;
  Result.HOLD22ID :=AGLCCIDS.HOLD22ID;
  Result.HOLD23ID :=AGLCCIDS.HOLD23ID;
  Result.HOLD24ID :=AGLCCIDS.HOLD24ID;
  Result.HOLD25ID :=AGLCCIDS.HOLD25ID;
  Result.HOLD26ID :=AGLCCIDS.HOLD26ID;
  Result.HOLD27ID :=AGLCCIDS.HOLD27ID;
  Result.HOLD28ID :=AGLCCIDS.HOLD28ID;
  Result.HOLD29ID :=AGLCCIDS.HOLD29ID;
  Result.HOLD30ID :=AGLCCIDS.HOLD30ID;
  Result.SETYEAR  :=AGLCCIDS.SETYEAR;
  Result.BISID    :=AGLCCIDS.BISID;
  Result.INPMID   :=AGLCCIDS.INPMID;
  Result.STID     :=AGLCCIDS.STID;
  Result.CTID     :=AGLCCIDS.CTID;
  Result.SMID     :=AGLCCIDS.SMID;
  Result.OPUSERID :=AGLCCIDS.OPUSERID;
  Result.EDITORID :=AGLCCIDS.EDITORID;
  Result.GBID     :=AGLCCIDS.GBID;
  Result.FMID     :=AGLCCIDS.FMID;
  Result.ASCODE   :=AGLCCIDS.ASCODE;
  Result.ASNAME   :=AGLCCIDS.ASNAME;
  Result.ENCODE   :=AGLCCIDS.ENCODE;
  Result.ENNAME   :=AGLCCIDS.ENNAME;
  Result.MKCODE   :=AGLCCIDS.MKCODE;
  Result.MKNAME   :=AGLCCIDS.MKNAME;
  Result.BSCODE   :=AGLCCIDS.BSCODE;
  Result.BSNAME   :=AGLCCIDS.BSNAME;
  Result.BICODE   :=AGLCCIDS.BICODE;
  Result.BINAME   :=AGLCCIDS.BINAME;
  Result.BSICODE  :=AGLCCIDS.BSICODE;
  Result.BSINAME  :=AGLCCIDS.BSINAME;
  Result.PKCODE   :=AGLCCIDS.PKCODE;
  Result.PKNAME   :=AGLCCIDS.PKNAME;
  Result.BOCODE   :=AGLCCIDS.BOCODE;
  Result.BONAME   :=AGLCCIDS.BONAME;
  Result.BKCODE   :=AGLCCIDS.BKCODE;
  Result.BKNAME   :=AGLCCIDS.BKNAME;
  Result.MBCODE   :=AGLCCIDS.MBCODE;
  Result.MBNAME   :=AGLCCIDS.MBNAME;
  Result.FILECODE :=AGLCCIDS.FILECODE;
  Result.FILENAME :=AGLCCIDS.FILENAME;
  Result.PMCODE   :=AGLCCIDS.PMCODE;
  Result.PMNAME   :=AGLCCIDS.PMNAME;
  Result.INBSCODE :=AGLCCIDS.INBSCODE;
  Result.INBSNAME :=AGLCCIDS.INBSNAME;
  Result.INBISCODE:=AGLCCIDS.INBISCODE;
  Result.INBISNAME:=AGLCCIDS.INBISNAME;
  Result.CBCODE   :=AGLCCIDS.CBCODE;
  Result.CBNAME   :=AGLCCIDS.CBNAME;
  Result.PBCODE   :=AGLCCIDS.PBCODE;
  Result.PBNAME   :=AGLCCIDS.PBNAME;
  Result.IBCODE   :=AGLCCIDS.IBCODE;
  Result.IBNAME   :=AGLCCIDS.IBNAME;
  Result.BACCODE  :=AGLCCIDS.BACCODE;
  Result.BACNAME  :=AGLCCIDS.BACNAME;
  Result.BAPCODE  :=AGLCCIDS.BAPCODE;
  Result.BAPNAME  :=AGLCCIDS.BAPNAME;
  Result.BAICODE  :=AGLCCIDS.BAICODE;
  Result.BAINAME  :=AGLCCIDS.BAINAME;
  Result.BTCODE   :=AGLCCIDS.BTCODE;
  Result.BTNAME   :=AGLCCIDS.BTNAME;
  Result.BPCODE   :=AGLCCIDS.BPCODE;
  Result.BPNAME   :=AGLCCIDS.BPNAME;
  Result.BLCODE   :=AGLCCIDS.BLCODE;
  Result.BLNAME   :=AGLCCIDS.BLNAME;
  Result.HOLD1CODE:=AGLCCIDS.HOLD1CODE;
  Result.HOLD1NAME:=AGLCCIDS.HOLD1NAME;
  Result.HOLD2CODE:=AGLCCIDS.HOLD2CODE;
  Result.HOLD2NAME:=AGLCCIDS.HOLD2NAME;
  Result.HOLD3CODE:=AGLCCIDS.HOLD3CODE;
  Result.HOLD3NAME:=AGLCCIDS.HOLD3NAME;
  Result.HOLD4CODE:=AGLCCIDS.HOLD4CODE;
  Result.HOLD4NAME:=AGLCCIDS.HOLD4NAME;
  Result.HOLD5CODE:=AGLCCIDS.HOLD5CODE;
  Result.HOLD5NAME:=AGLCCIDS.HOLD5NAME;
  Result.HOLD6CODE:=AGLCCIDS.HOLD6CODE;
  Result.HOLD6NAME:=AGLCCIDS.HOLD6NAME;
  Result.HOLD7CODE:=AGLCCIDS.HOLD7CODE;
  Result.HOLD7NAME:=AGLCCIDS.HOLD7NAME;
  Result.HOLD8CODE:=AGLCCIDS.HOLD8CODE;
  Result.HOLD8NAME:=AGLCCIDS.HOLD8NAME;
  Result.HOLD9CODE:=AGLCCIDS.HOLD9CODE;
  Result.HOLD9NAME:=AGLCCIDS.HOLD9NAME;
  Result.HOLD10CODE:=AGLCCIDS.HOLD10CODE;
  Result.HOLD10NAME:=AGLCCIDS.HOLD10NAME;
  Result.HOLD11CODE:=AGLCCIDS.HOLD11CODE;
  Result.HOLD11NAME:=AGLCCIDS.HOLD11NAME;
  Result.HOLD12CODE:=AGLCCIDS.HOLD12CODE;
  Result.HOLD12NAME:=AGLCCIDS.HOLD12NAME;
  Result.HOLD13CODE:=AGLCCIDS.HOLD13CODE;
  Result.HOLD13NAME:=AGLCCIDS.HOLD13NAME;
  Result.HOLD14CODE:=AGLCCIDS.HOLD14CODE;
  Result.HOLD14NAME:=AGLCCIDS.HOLD14NAME;
  Result.HOLD15CODE:=AGLCCIDS.HOLD15CODE;
  Result.HOLD15NAME:=AGLCCIDS.HOLD15NAME;
  Result.HOLD16CODE:=AGLCCIDS.HOLD16CODE;
  Result.HOLD16NAME:=AGLCCIDS.HOLD16NAME;
  Result.HOLD17CODE:=AGLCCIDS.HOLD17CODE;
  Result.HOLD17NAME:=AGLCCIDS.HOLD17NAME;
  Result.HOLD18CODE:=AGLCCIDS.HOLD18CODE;
  Result.HOLD18NAME:=AGLCCIDS.HOLD18NAME;
  Result.HOLD19CODE:=AGLCCIDS.HOLD19CODE;
  Result.HOLD19NAME:=AGLCCIDS.HOLD19NAME;
  Result.HOLD20CODE:=AGLCCIDS.HOLD20CODE;
  Result.HOLD20NAME:=AGLCCIDS.HOLD20NAME;
  Result.HOLD21CODE:=AGLCCIDS.HOLD21CODE;
  Result.HOLD21NAME:=AGLCCIDS.HOLD21NAME;
  Result.HOLD22CODE:=AGLCCIDS.HOLD22CODE;
  Result.HOLD22NAME:=AGLCCIDS.HOLD22NAME;
  Result.HOLD23CODE:=AGLCCIDS.HOLD23CODE;
  Result.HOLD23NAME:=AGLCCIDS.HOLD23NAME;
  Result.HOLD24CODE:=AGLCCIDS.HOLD24CODE;
  Result.HOLD24NAME:=AGLCCIDS.HOLD24NAME;
  Result.HOLD25CODE:=AGLCCIDS.HOLD25CODE;
  Result.HOLD25NAME:=AGLCCIDS.HOLD25NAME;
  Result.HOLD26CODE:=AGLCCIDS.HOLD26CODE;
  Result.HOLD26NAME:=AGLCCIDS.HOLD26NAME;
  Result.HOLD27CODE:=AGLCCIDS.HOLD27CODE;
  Result.HOLD27NAME:=AGLCCIDS.HOLD27NAME;
  Result.HOLD28CODE:=AGLCCIDS.HOLD28CODE;
  Result.HOLD28NAME:=AGLCCIDS.HOLD28NAME;
  Result.HOLD29CODE:=AGLCCIDS.HOLD29CODE;
  Result.HOLD29NAME:=AGLCCIDS.HOLD29NAME;
  Result.HOLD30CODE:=AGLCCIDS.HOLD30CODE;
  Result.HOLD30NAME:=AGLCCIDS.HOLD30NAME;
  Result.BISCODE  :=AGLCCIDS.BISCODE;
  Result.BISNAME  :=AGLCCIDS.BISNAME;
  Result.INPMCODE :=AGLCCIDS.INPMCODE;
  Result.INPMNAME :=AGLCCIDS.INPMNAME;
  Result.STCODE   :=AGLCCIDS.STCODE;
  Result.STNAME   :=AGLCCIDS.STNAME;
  Result.CTCODE   :=AGLCCIDS.CTCODE;
  Result.CTNAME   :=AGLCCIDS.CTNAME;
  Result.SMCODE   :=AGLCCIDS.SMCODE;
  Result.SMNAME   :=AGLCCIDS.SMNAME;
  Result.OPUSERCODE:=AGLCCIDS.OPUSERCODE;
  Result.OPUSERNAME:=AGLCCIDS.OPUSERNAME;
  Result.EDITORCODE:=AGLCCIDS.EDITORCODE;
  Result.EDITORNAME:=AGLCCIDS.EDITORNAME;
  Result.GBCODE   :=AGLCCIDS.GBCODE;
  Result.GBNAME   :=AGLCCIDS.GBNAME;
  Result.FMCODE   :=AGLCCIDS.FMCODE;
  Result.FMNAME   :=AGLCCIDS.FMNAME;
  Result.PAYACCOUNTNO:=AGLCCIDS.PAYACCOUNTNO;
  Result.PAYACCOUNTNAME:=AGLCCIDS.PAYACCOUNTNAME;
  Result.PAYACCOUNTBANK:=AGLCCIDS.PAYACCOUNTBANK;
  Result.CLEARACCOUNTNO:=AGLCCIDS.CLEARACCOUNTNO;
  Result.CLEARACCOUNTNAME:=AGLCCIDS.CLEARACCOUNTNAME;
  Result.CLEARACCOUNTBANK:=AGLCCIDS.CLEARACCOUNTBANK;
  Result.INCOMEACCOUNTNO:=AGLCCIDS.INCOMEACCOUNTNO;
  Result.INCOMEACCOUNTNAME:=AGLCCIDS.INCOMEACCOUNTNAME;
  Result.INCOMEACCOUNTBANK:=AGLCCIDS.INCOMEACCOUNTBANK;
  Result.PFID     :=AGLCCIDS.PFID;
  Result.PFCODE   :=AGLCCIDS.PFCODE;
  Result.PFNAME   :=AGLCCIDS.PFNAME;
  Result.GROUPIDID:=AGLCCIDS.GROUPIDID;
  Result.GROUPIDCODE:=AGLCCIDS.GROUPIDCODE;
  Result.GROUPIDNAME:=AGLCCIDS.GROUPIDNAME;
  Result.USEENID  :=AGLCCIDS.USEENID;
  Result.USEENCODE:=AGLCCIDS.USEENCODE;
  Result.USEENNAME:=AGLCCIDS.USEENNAME;
  Result.PROVID   :=AGLCCIDS.PROVID;
  Result.PROVCODE :=AGLCCIDS.PROVCODE;
  Result.PROVNAME :=AGLCCIDS.PROVNAME;
  Result.AGENCYID :=AGLCCIDS.AGENCYID;
  Result.AGENCYCODE:=AGLCCIDS.AGENCYCODE;
  Result.AGENCYNAME:=AGLCCIDS.AGENCYNAME;
  Result.MODEID   :=AGLCCIDS.MODEID;
  Result.MODECODE :=AGLCCIDS.MODECODE;
  Result.MODENAME :=AGLCCIDS.MODENAME;
  Result.FASNID   :=AGLCCIDS.FASNID;
  Result.FASNCODE :=AGLCCIDS.FASNCODE;
  Result.FASNNAME :=AGLCCIDS.FASNNAME;
  Result.DIRID    :=AGLCCIDS.DIRID;
  Result.DIRCODE  :=AGLCCIDS.DIRCODE;
  Result.DIRNAME  :=AGLCCIDS.DIRNAME;
  Result.GPPLANID :=AGLCCIDS.GPPLANID;
  Result.GPPLANCODE:=AGLCCIDS.GPPLANCODE;
  Result.GPPLANNAME:=AGLCCIDS.GPPLANNAME;
  Result.GPBARNID :=AGLCCIDS.GPBARNID;
  Result.GPBARNCODE:=AGLCCIDS.GPBARNCODE;
  Result.GPBARNNAME:=AGLCCIDS.GPBARNNAME;
  Result.WAID     :=AGLCCIDS.WAID;
  Result.WACODE   :=AGLCCIDS.WACODE;
  Result.WANAME   :=AGLCCIDS.WANAME;
  Result.FFID     :=AGLCCIDS.FFID;
  Result.FFNAME   :=AGLCCIDS.FFNAME;
  Result.FFCODE   :=AGLCCIDS.FFCODE;
  Result.IENID    :=AGLCCIDS.IENID;
  Result.IENNAME  :=AGLCCIDS.IENNAME;
  Result.IENCODE  :=AGLCCIDS.IENCODE;
  Result.SALTAGID :=AGLCCIDS.SALTAGID;
  Result.SALTAGNAME:=AGLCCIDS.SALTAGNAME;
  Result.SALTAGCODE:=AGLCCIDS.SALTAGCODE;
  Result.BCID     :=AGLCCIDS.BCID;
  Result.BCCODE   :=AGLCCIDS.BCCODE;
  Result.BCNAME   :=AGLCCIDS.BCNAME;
  Result.BSOID    :=AGLCCIDS.BSOID;
  Result.BSOCODE  :=AGLCCIDS.BSOCODE;
  Result.BSONAME  :=AGLCCIDS.BSONAME;
  Result.AEID     :=AGLCCIDS.AEID;
  Result.AECODE   :=AGLCCIDS.AECODE;
  Result.AENAME   :=AGLCCIDS.AENAME;
  Result.CCID     :=AGLCCIDS.CCID;
  Result.BUDGETVOUID:=AGLCCIDS.BUDGETVOUID;
  Result.BUDGETVOUCODE:=AGLCCIDS.BUDGETVOUCODE;
  Result.BUDGETVOUNAME:=AGLCCIDS.BUDGETVOUNAME;
  Result.MD5      :=AGLCCIDS.MD5;
  Result.GPVOUID  :=AGLCCIDS.GPVOUID;
  Result.GPVOUCODE:=AGLCCIDS.GPVOUCODE;
  Result.GPVOUNAME:=AGLCCIDS.GPVOUNAME;
end;

function TGLCCIDS.ExpSQL: string;
begin
  Result:='SELECT * FROM GL_CCIDS WHERE 1=1'
         +'    AND EN_ID=%s'
         +'    AND MK_ID=%s'
         +'    AND BS_ID=%s'
         +'    AND BI_ID=%s'
         +'    AND PK_ID=%s'
         +'    AND BO_ID=%s'
         +'    AND MB_ID=%s'
         +'    AND FILE_ID=%s'
         +'    AND BT_ID=%s'
         +'    AND BP_ID=%s'
         +'    AND BL_ID=%s'
         +'    AND BIS_ID=%s'
         +'    AND INPM_ID=%s'
         +'    AND GROUPID_ID=%s'
         +'    AND USEEN_ID=%s'
         +'    AND SALTAG_ID=%s';
  Result:=Format(Result,[
                        QuotedStr(ENID),
                        QuotedStr(MKID),
                        QuotedStr(BSID),
                        QuotedStr(BIID),
                        QuotedStr(PKID),
                        QuotedStr(BOID),
                        QuotedStr(MBID),
                        QuotedStr(FILEID),
                        QuotedStr(BTID),
                        QuotedStr(BPID),
                        QuotedStr(BLID),
                        QuotedStr(BISID),
                        QuotedStr(INPMID),
                        QuotedStr(GROUPIDID),
                        QuotedStr(USEENID),
                        QuotedStr(SALTAGID)
                        ]);
         
end;

function TGLCCIDS.GetNextMAXX(AUniConnection: TUniConnection): Extended;
var
  SQLA:string;
begin
  SQLA:='SELECT MAX(CCID)+1  AS VALUE FROM GL_CCIDS WHERE COA_ID=%S';
  SQLA:=Format(SQLA,[QuotedStr(COAID)]);
  Result:=CheckField(SQLA,'VALUE',AUniConnection);
end;


end.

